-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
example of how to run code-server with nginx and docker compose #7039
Comments
Our docs should work in a container as well. We could maintain compose files for NGINX but I am not sure we want to be prescriptive on what reverse proxies folks should be using. What have you tried and what specific error or behavior are you seeing? |
thanks for your response. code server does work in a container, don't get me wrong - what i can't seem to get to work is the redirect after entering the password. it just reloads the login page. i've tried the my goal is to have a few of these code server instances that i can use for different things/projects/people and handle the redirects to each via subdomains. i guess i could just implement auth in another layer and remove the password from code server. code server does work as expected without the password. |
@code-asher have you had a chance to look into this? i'd really like to get this working. |
I was offline last week so I have not looked into it yet. Could you share your NGINX config? |
It does sort of sound like the cookie somehow is dropped so code-server thinks you are not logged in but I am not sure how that would happen. Happy to poke around if you can provide a way for me to reproduce. |
omg!!!I encountered the same issue, where I couldn't access the workspace after entering my password. Initially, I deployed using the NAT server I purchased (which has no public IP, and the vendor set up DDNS), but Jupyter Notebook couldn't display code blocks properly due to the lack of an SSL certificate (it displayed correctly when tested via VNC on the server). So, I used Alibaba Cloud's CDN service, pointing another domain to the original URL with a CNAME record. However, at this point, after entering my password, I still couldn't access the workspace and was stuck on a reloading login page. My issue might be too niche to warrant a solution, but I'm still trying to find a way to resolve it. |
The SSL certificate has been successfully deployed, and I can access it via HTTPS, but I'm still stuck on the login page. |
Strange, so you submit the password and if you check the network requests, is it making a redirect to the root and then back to the login page? It is not redirecting to the original URL or anything wonky like that? Similar to above, the first thing that comes to mind is that somehow the |
What is your suggestion?
it would be great to see an example of how to get code-server to work with docker containers using docker compose and nginx/certbot for reverse proxy and tls.
How will this improve the docs?
would make it easy to get this running. i use this pattern all over the place and it simply doesn't work with code-server when there's a password enabled. the redirect after entering the password just doesn't work. i follow the docs, or how i interpret what is meant, and it won't work.
Are you interested in submitting a PR for this?
if i could get it to work..
The text was updated successfully, but these errors were encountered: