fix: propagate execArgv (#5510)
* Use fork instead of spawn We no longer do in-place updating so no need for the spawn. The advantage of a fork is that it preserves flags like --prof which you can use to profile code-server. Also I am not sure the comment about not being able to reload in place with fork was even true to begin with. * Refresh heartbeat patch Seems to have gotten out of date a little. * Propagate execArgv to extension host This will let us profile the extension host.
This commit is contained in:
@ -317,8 +317,7 @@ export class ParentProcess extends Process {
|
||||
}
|
||||
|
||||
private spawn(): cp.ChildProcess {
|
||||
// Use spawn (instead of fork) to use the new binary in case it was updated.
|
||||
return cp.spawn(process.argv[0], process.argv.slice(1), {
|
||||
return cp.fork(path.join(__dirname, "entry"), {
|
||||
env: {
|
||||
...process.env,
|
||||
CODE_SERVER_PARENT_PID: process.pid.toString(),
|
||||
|
Reference in New Issue
Block a user