Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix docker compose up in sirix-rest-api #707

Closed
JohannesLichtenberger opened this issue Mar 16, 2024 · 17 comments
Closed

Fix docker compose up in sirix-rest-api #707

JohannesLichtenberger opened this issue Mar 16, 2024 · 17 comments

Comments

@JohannesLichtenberger
Copy link
Member

Fix docker compose up regarding the Github Action (currently the tests fail)...

@traitsisgiorgos
Copy link

hi, can you give same info for the problem?

@JohannesLichtenberger
Copy link
Member Author

The Github Action currently fails, because something apparently fails during the Docker container start, but I'm not sure how to log the error and locally it starts fine: https://github.com/sirixdb/sirix/actions/runs/8305202119

@JohannesLichtenberger
Copy link
Member Author

johannes@luna:~/IdeaProjects/sirix/bundles/sirix-rest-api/src/test/resources$ sudo docker compose -f docker-compose.yml --ansi never -p sirix-test up -d
 Container sirix-test-keycloak-1  Starting
 Container sirix-test-keycloak-1  Started

The stack trace in https://productionresultssa1.blob.core.windows.net/actions-results/ff8681a6-8947-40d6-9379-fac9fc03909c/workflow-job-run-5264e576-3c6f-51f6-f055-fab409685f20/logs/job/job-logs.txt?rsct=text%2Fplain&se=2024-03-17T11%3A41%3A57Z&sig=6cHBO4TinZxf6e6lnLP0Nwm4ot%2FCeY2i1PgS2yIgjx4%3D&sp=r&spr=https&sr=b&st=2024-03-17T11%3A31%3A52Z&sv=2021-12-02:

2024-03-17T04:09:05.0425707Z 2024-03-17T04:09:04.433+0000 [INFO] [org.gradle.process.internal.DefaultExecHandle] Starting process 'command 'docker''. Working directory: /home/runner/work/sirix/sirix/bundles/sirix-rest-api Command: docker compose -f /home/runner/work/sirix/sirix/bundles/sirix-rest-api/src/test/resources/docker-compose.yml --ansi never -p sirix-test up -d
2024-03-17T04:09:05.0429169Z 2024-03-17T04:09:04.433+0000 [DEBUG] [org.gradle.process.internal.DefaultExecHandle] Changing state to: STARTING
2024-03-17T04:09:05.0497857Z 2024-03-17T04:09:04.435+0000 [DEBUG] [org.gradle.process.internal.DefaultExecHandle] Waiting until process started: command 'docker'.
2024-03-17T04:09:05.0499946Z 2024-03-17T04:09:04.449+0000 [DEBUG] [org.gradle.process.internal.DefaultExecHandle] Changing state to: STARTED
2024-03-17T04:09:05.0501876Z 2024-03-17T04:09:04.449+0000 [DEBUG] [org.gradle.process.internal.ExecHandleRunner] waiting until streams are handled...
2024-03-17T04:09:05.0504160Z 2024-03-17T04:09:04.449+0000 [INFO] [org.gradle.process.internal.DefaultExecHandle] Successfully started process 'command 'docker''
2024-03-17T04:09:05.0506126Z 2024-03-17T04:09:04.862+0000 [DEBUG] [org.gradle.process.internal.DefaultExecHandle] Changing state to: FAILED
2024-03-17T04:09:05.0508332Z 2024-03-17T04:09:04.863+0000 [DEBUG] [org.gradle.process.internal.DefaultExecHandle] Process 'command 'docker'' finished with exit value 18 (state: FAILED)
2024-03-17T04:09:05.0510482Z 2024-03-17T04:09:04.865+0000 [DEBUG] [org.gradle.api.Task] Failed to start-up Docker containers
2024-03-17T04:09:05.0512484Z java.lang.RuntimeException: Exit-code 18 when calling docker-compose, stdout: java.io.FileOutputStream@5c88feed
2024-03-17T04:09:05.0514380Z 	at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.newInstance(DirectConstructorHandleAccessor.java:62)
2024-03-17T04:09:05.0516228Z 	at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:502)
2024-03-17T04:09:05.0517543Z 	at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:486)
2024-03-17T04:09:05.0518855Z 	at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:72)
2024-03-17T04:09:05.0520426Z 	at org.codehaus.groovy.reflection.CachedConstructor.doConstructorInvoke(CachedConstructor.java:59)
...

@Stredsto
Copy link

can I look into this?

@JohannesLichtenberger
Copy link
Member Author

@Stredsto any progress already?

@Stredsto
Copy link

Stredsto commented Apr 3, 2024

Hey @JohannesLichtenberger,
I was having some setup issues, also got a little busy at work, will continue again on this today.
Finish any setup issues and then this

@Stredsto
Copy link

Stredsto commented Apr 3, 2024

Hello @JohannesLichtenberger .
I continued with the setup again, I am able to start the docker for keycloak, but docker image for sirixdb just wont get up,
I believe this is what I have to start to run the main application because if I directly run Main.java from intellij, that's just keep running for hours.

@JohannesLichtenberger
Copy link
Member Author

That's the main issue I guess, that the container for some reason doesn't start. Can you check the docker log for the container?

@Stredsto
Copy link

Stredsto commented Apr 3, 2024

yeah looking through it

@Stredsto
Copy link

Stredsto commented Apr 7, 2024

yeah looking through it

[vert.x-eventloop-thread-0] ERROR i.v.c.i.l.c.VertxIsolatedDeployer - Failed in deploying verticle
io.vertx.core.impl.NoStackTraceThrowable: Not Found: {"error":"Unable to find matching target resource method","error_description":"For more on this error consult the server log at the debug level."}

any idea, what does this error exactly means?

@Stredsto
Copy link

Stredsto commented Apr 8, 2024

hey @JohannesLichtenberger, is this fixed by someone ?

@JohannesLichtenberger
Copy link
Member Author

JohannesLichtenberger commented Apr 8, 2024

I've fixed the docker image specification, as it didn't exist anymore (quay.io/keycloak/keycloak:7.0.1 instead of jboss/keycloak:7.0.1).

@JohannesLichtenberger
Copy link
Member Author

That said we have to update to the newest keycloak version and check why it doesn't start anymore.

@Stredsto
Copy link

Stredsto commented Apr 9, 2024

@JohannesLichtenberger keycloak starts well in my local docker setup

keycloak: image: quay.io/keycloak/keycloak ports: - 8080:8080 - 8433:8433 environment: - KEYCLOAK_USER=admin - KEYCLOAK_ADMIN=admin - KEYCLOAK_PASSWORD=admin - KEYCLOAK_ADMIN_PASSWORD=admin - KEYCLOAK_LOGLEVEL=DEBUG - KEYCLOAK_IMPORT=/opt/keycloak/realm-export.json restart: always

tho I had to add these :

KEYCLOAK_ADMIN=admin
KEYCLOAK_ADMIN_PASSWORD=admin

@JohannesLichtenberger
Copy link
Member Author

@Stredsto you like to make a PR? There's a docker compose file in the parent directory (project root), one in sirix-rest-api/src/test/resources and one in the sirix-python-client :-)

@Stredsto
Copy link

Stredsto commented Apr 9, 2024

@JohannesLichtenberger Sure, I'll do the PR

@Stredsto
Copy link

Stredsto commented Apr 9, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants