code-server
code-server copied to clipboard
[Bug]: code-sever in docker not remember github auth
Is there an existing issue for this?
- [X] I have searched the existing issues
OS/Web Information
- Web Browser:
- Local OS:
- Remote OS:
- Remote Architecture:
-
code-server --version
:
Steps to Reproduce
- run code server docker image
- code server web and login github (copilot)
- restart code server container and it asks to github copilot login again
Expected
remember my github auth for copilot
Actual
no
Logs
No response
Screenshot/Video
No response
Does this issue happen in VS Code or GitHub Codespaces?
- [X] I cannot reproduce this in VS Code.
- [X] I cannot reproduce this in GitHub Codespaces.
Are you accessing code-server over a secure context?
- [X] I am using a secure context.
Notes
No response
Are you mounting your data directory (~./local/share/code-server
by default)? If the contents are not being persisted between Docker restarts then code-server will be unable to access the previous auth token.
Are you mounting your data directory (
~./local/share/code-server
by default)? If the contents are not being persisted between Docker restarts then code-server will be unable to access the previous auth token.
Yes, we mount the home dir (~). But it still requires github login each time. Which file stores the github auth?
The actual GitHub auth token is stored in browser storage, but it is encrypted and half of the key is in ~/.local/share/code-server/serve-web-key-half
. The other half of the key is also in browser storage, I believe.
So as long as the server key half is the same and the browser is the same the login should persist.
Also, what version of code-server are you running? Persistent secret storage was broken before 4.17.1.
@code1704 I think this can be closed, this is the same as #5072