Code-server: Code Server 3.7.0 - Failed startup with .deb

Created on 16 Nov 2020  路  7Comments  路  Source: cdr/code-server

When trying to build Code Server 3.7.0:
'''
internal/modules/cjs/loader.js:968
throw err;
^
Error: Cannot find module '/usr/lib/code-server'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:965:15)
at Function.Module._load (internal/modules/cjs/loader.js:841:27)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:71:1
2)
at internal/main/run_main_module.js:17:47 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
'''
Successful build with Code Server 3.6.2:
'''
[2020-11-16T20:59:11.197Z] info Wrote default config file to ~/.config/code-server/config.yaml
[2020-11-16T20:59:11.443Z] info Using user-data-dir ~/.local/share/code-server
[2020-11-16T20:59:11.450Z] info code-server 3.6.2 9bde62fbd611a7a91c5f327fa43e0d06f1379169
[2020-11-16T20:59:11.450Z] info Using config file ~/.config/code-server/config.yaml
[2020-11-16T20:59:11.455Z] info HTTP server listening on http://127.0.0.1:8080
[2020-11-16T20:59:11.455Z] info - Using password from ~/.config/code-server/config.yaml
[2020-11-16T20:59:11.455Z] info - To disable use --auth none
[2020-11-16T20:59:11.455Z] info - Not serving HTTPS
'''
-->

  • Web Browser: Chrome
  • Local OS: Windows
  • Remote OS: Google Cloud Shell & Windows
  • Remote Architecture: Unknown
  • `code-server --version :3.7.0
bug priority

Most helpful comment

All 7 comments

I tested the version 3.7.0 and i found the same problem:

internal/modules/cjs/loader.js:968
  throw err;
  ^

Error: Cannot find module '/usr/lib/code-server'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:965:15)
    at Function.Module._load (internal/modules/cjs/loader.js:841:27)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:71:12)
    at internal/main/run_main_module.js:17:47 {
  code: 'MODULE_NOT_FOUND',
  requireStack: []
}

The new install path of dpkg is: /usr/lib/code-server/bin

Putting out a hotfix right now for this! Thanks for reporting.

The standalone archives and macOS release work fine.

This problem is specific to the rpm and deb releases!

Affect official docker image too :) https://hub.docker.com/r/codercom/code-server

Is a bug in nfpm, apologies for letting this slip through!

See https://github.com/goreleaser/nfpm/issues/232#issuecomment-728347931

I'm going to make a 3.7.1 release with the fixed debs/rpms.

Thanks @nhooyr for your super fast fix 馃憤

Was this page helpful?
0 / 5 - 0 ratings

Related issues

nol166 picture nol166  路  3Comments

pchecinski picture pchecinski  路  3Comments

korzq picture korzq  路  3Comments

lshamis picture lshamis  路  3Comments

justmao945 picture justmao945  路  3Comments