Closed kaaax0815 closed 3 years ago
I figured out, when entering the Site and waiting like 10mins it works. I immediately went on a file, and this was i think bad.
using --link
fixed like every problem, extensions load fast, the code shows instantly, syntax highlight works after only a second. Maybe its a problem with caddy. I think I am removing caddy and trying nginx (doesnt work well https://github.com/cdr/code-server/discussions/2593). The thing is, because caddy works with another service just fine, I'll use caddy as redirect to the --link
I figured out, when entering the Site and waiting like 10mins it works.
Something seems very wrong here but I'm not sure. Have you followed our setup guide linked in the README that explains how to setup caddy or nginx?
I exactly followed the guide, but as i mentioned i have a weird dns, i think our proxy does some thing. With nginx I get 502 mentioned in #2593
I used many other Hoster now and everywhere its works just fine, its either the only 1 core and 1gb ram or the missing IPv4 support. The nice thing is, that --link
makes it work just fine
I discovered this issue repeating following logs
TRACE Started scanning user extensions
TRACE [Error: ENOENT: no such file or directory, open '/usr/lib/code-server/lib/vscode/extensions/node_modules/package.json'] {
errno: -2,
code: 'ENOENT',
syscall: 'open',
path: '/usr/lib/code-server/lib/vscode/extensions/node_modules/package.json'
}
TRACE [Error: ENOTDIR: not a directory, scandir '/usr/lib/code-server/lib/vscode/extensions/package.json'] {
errno: -20,
code: 'ENOTDIR',
syscall: 'scandir',
path: '/usr/lib/code-server/lib/vscode/extensions/package.json'
}
TRACE [Error: ENOTDIR: not a directory, scandir '/usr/lib/code-server/lib/vscode/extensions/postinstall.js'] {
errno: -20,
code: 'ENOTDIR',
syscall: 'scandir',
path: '/usr/lib/code-server/lib/vscode/extensions/postinstall.js'
}
TRACE Scanned user extensions: 28
TRACE [Error: ENOTDIR: not a directory, scandir '/usr/lib/code-server/lib/vscode/extensions/yarn.lock'] {
errno: -20,
code: 'ENOTDIR',
syscall: 'scandir',
path: '/usr/lib/code-server/lib/vscode/extensions/yarn.lock'
}
TRACE Scanned system extensions: 85
TRACE [File Watcher (node.js)] [CHANGED] /home/username/.local/share/code-server/User/state/global.json
TRACE [File Watcher (node.js)] [CHANGED] /home/username/.local/share/code-server/User/state/global.json
TRACE [File Watcher (node.js)] >> normalized [CHANGED] /home/username/.local/share/code-server/User/state/global.json
TRACE [File Watcher (node.js)] [CHANGED] /home/username/.local/share/code-server/User/state/global.json
TRACE [File Watcher (node.js)] >> normalized [CHANGED] /home/username/.local/share/code-server/User/state/global.json
TRACE Started scanning user extensions
TRACE Scanned user extensions: 28
[2021-03-27T07:33:23.998Z] debug vscode got message from code-server {"type":"socket"}
[2021-03-27T07:33:23.998Z] trace vscode code-server message content {"message":{"type":"socket","query":{"reconnectionToken":"REDACTED-TOKEN","reconnection":"true","skipWebSocketFrames":"false"},"permessageDeflate":true}}
[2021-03-27T07:33:24.001Z] trace vscode Protocol handshake {"token":"REDACTED-TOKEN"}
[2021-03-27T07:33:24.003Z] trace vscode Protocol message {"token":"REDACTED-TOKEN","message":"{\"type\":\"auth\",\"auth\":\"00000000000000000000\"}"}
[2021-03-27T07:33:24.009Z] trace vscode Protocol message {"token":"REDACTED-TOKEN","message":"{\"type\":\"connectionType\",\"commit\":\"109d2ce3247869eaeab67aa7e5423503ec9eb859\",\"signedData\":\"\",\"desiredConnectionType\":2,\"args\":{\"language\":\"en\",\"break\":false,\"port\":null}}"}
[2021-03-27T07:33:24.010Z] trace exthost Sending socket {"token":"REDACTED-TOKEN"}
[2021-03-27T07:33:24.012Z] warn vscode Socket is closed
[2021-03-27T07:33:38.269Z] trace 2 active connections
[2021-03-27T07:33:38.270Z] trace heartbeat
[2021-03-27T07:33:44.051Z] debug vscode got message from code-server {"type":"socket"}
[2021-03-27T07:33:44.052Z] trace vscode code-server message content {"message":{"type":"socket","query":{"reconnectionToken":"REDACTED-TOKEN","reconnection":"true","skipWebSocketFrames":"false"},"permessageDeflate":true}}
[2021-03-27T07:33:44.052Z] trace vscode Protocol handshake {"token":"REDACTED-TOKEN"}
[2021-03-27T07:33:44.055Z] trace vscode Protocol message {"token":"REDACTED-TOKEN","message":"{\"type\":\"auth\",\"auth\":\"00000000000000000000\"}"}
[2021-03-27T07:33:44.057Z] trace vscode Protocol message {"token":"REDACTED-TOKEN","message":"{\"type\":\"connectionType\",\"commit\":\"109d2ce3247869eaeab67aa7e5423503ec9eb859\",\"signedData\":\"\",\"desiredConnectionType\":2,\"args\":{\"language\":\"en\",\"break\":false,\"port\":null}}"}
[2021-03-27T07:33:44.058Z] trace exthost Sending socket {"token":"REDACTED-TOKEN"}
It seems losing/denying socket connection and retrying, which results in improperly working extensions (for example cannot track git difference) and some other things.
Interestingly it is okay with HTTP direct connection. So the problem is with HTTPS reverse proxy (traefik in my case). However, there's no luck for any workarounds. I will try it with other reverse proxies like nginx.
The issue described above is nothing to do with reverse proxy solution. It is sorted out by re-installation using npm from scratch. In my guess, something is broken with pre-built deb package for ubuntu.
Now I tried opening the website (sudomain via caddy), it showed the login page successfully, accepted the password, and loads a white page forever, and theres no error message or any message at all in the log
Startup Log:
Log when loading website:
When using the
--link
Parameters, it works fine.Caddy Startup Log:
Browser Log (Error):
Addition: I have Cloudcmd Running using Caddy Reverse Proxy It works sometimes, sometimes not I cant ping, or curl github, so I installed it manually using the deb-Package Specs: 1 Gb Ram 7gb Remaining Storage Intel(R) Xeon(R) CPU E3-1270 V2 @ 3.50GHz Cpu Usage about 25%
No waiting 30mins, it loaded the Ui but stillt doesnt load files. I dont have Internet neither the server