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

error with docker compose #13

Closed
koebel opened this issue Apr 4, 2024 · 4 comments
Closed

error with docker compose #13

koebel opened this issue Apr 4, 2024 · 4 comments

Comments

@koebel
Copy link
Contributor

koebel commented Apr 4, 2024

When I build the app according to the instructions given in the README.md I get the following error message regarding the connectivity on endpoint of 3d_viewer. However the app seems to be running correctly in the browser.

Kathrins-MacBook-Pro-2:web-app-3dmodel-viewer k2$ docker compose up
[+] Running 3/3
 ⠿ Network "web-app-3dmodel-viewer_default"  Created                       3.4s
 ⠿ Container web                             Created                       0.2s
 ⠿ Container 3d_viewer                       Crea...                       0.2s
Attaching to 3d_viewer, web
The new 'docker compose' command is currently experimental. To provide feedback or request new features please open issues at https://github.com/docker/compose-cli
Error response from daemon: driver failed programming external connectivity on endpoint 3d_viewer (9a1fd50a7480b25efff7d2a23e5161830b28e517f27bfe9fd8d8f8634e5e894a): Bind for 0.0.0.0:3000 failed: port is already allocated
Kathrins-MacBook-Pro-2:web-app-3dmodel-viewer k2$ docker ps -al
CONTAINER ID   IMAGE          COMMAND                  CREATED          STATUS    PORTS     NAMES
5e86721ed6d5   nginx:1.25.3   "/docker-entrypoint.…"   23 seconds ago   Created             3d_viewer
@saw-jan
Copy link
Owner

saw-jan commented Apr 4, 2024

Bind for 0.0.0.0:3000 failed: port is already allocated

The problem is this one. Could you find out what is running at port 3000?

@koebel
Copy link
Contributor Author

koebel commented Apr 4, 2024

sorry, ports were not listed in the code I copied above. but it's the app listed there. I didn't had anything else running on docker, only the app which was started using this command
docker run --rm -p3000:80 sawjan/web-app-3dmodel-viewer
which obviously does uses port 3000. Maybe I misunderstood the README... Is the docker container a precondition for building and running the app or an alternative?

@saw-jan
Copy link
Owner

saw-jan commented Apr 4, 2024

Ah, now I see the problem.

docker run --rm -p3000:80 sawjan/web-app-3dmodel-viewer

This command is only meant to run when you are manually setting up the extension server and ocis separately.
If you are using docker compose setup then no need to start extension server separately using docker run ...

When setting locally for development, only follow this section https://github.com/saw-jan/web-app-3dmodel-viewer?tab=readme-ov-file#build-and-run. Then all should be fine

Docker Image is a separate topic

@koebel
Copy link
Contributor Author

koebel commented Apr 4, 2024

I've made some small changes in the documentation to make this clearer, see #14

@koebel koebel closed this as completed Apr 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants