Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Agent hangs on 'connecting' when deploying using code-server docker template #3514

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

Closed
AadamZ5 opened this issue Aug 15, 2022 · 1 comment
Closed
Assignees

Comments

@AadamZ5
Copy link

AadamZ5 commented Aug 15, 2022

This is almost identical to #3513 but the container is using a different URL to try and reach the host. This is with the docker-code-server template.

Container log:

+ trap waitonexit EXIT
+ mktemp -d -t coder.XXXXXX
+ BINARY_DIR=/tmp/coder.zDnaVV
+ BINARY_NAME=coder
+ BINARY_URL=http://host.docker.internal:3000/bin/coder-linux-amd64
+ cd /tmp/coder.zDnaVV
+ :
+ status=
+ command -v curl
+ curl -fsSL --compressed http://host.docker.internal:3000/bin/coder-linux-amd64 -o coder
curl: (7) Failed to connect to host.docker.internal port 3000: Connection refused
+ status=7
+ echo error: failed to download coder agent
+ echo        command returned: 7
+ echo Trying again in 30 seconds...
+ sleep 30
error: failed to download coder agent
       command returned: 7
Trying again in 30 seconds...
+ :
+ status=
+ command -v curl
+ curl -fsSL --compressed http://host.docker.internal:3000/bin/coder-linux-amd64 -o coder
curl: (7) Failed to connect to host.docker.internal port 3000: Connection refused
+ status=7
+ echo error: failed to download coder agent
+ echo        command returned: 7
+ echo Trying again in 30 seconds...
+ sleep 30

Similar to the related issue, the container can't reach the host network. However, this container is using the host.docker.internal URL instead of 127.0.0.1 like in #3513. I'm not quite sure why host.docker.internal is not working, since it should be a bound host name in the container. Just looking now, this documentation says that this is for development features only, and will not work outside of docker desktop. Potentially the problem?

> coder version
Coder v0.8.5+95f26f7 Wed Aug 10 16:30:46 UTC 2022
https://github.com/coder/coder/commit/95f26f74b6ff6be1ffe42fceb21f70219889dc99
@kylecarbs kylecarbs self-assigned this Aug 18, 2022
@kylecarbs
Copy link
Member

Closing in favor of #3513

@kylecarbs kylecarbs closed this as not planned Won't fix, can't repro, duplicate, stale Aug 30, 2022
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