fix(worker): remount / to /host/root
This commit is contained in:
parent
7c967271d7
commit
230ae0a412
4 changed files with 5 additions and 1 deletions
|
@ -80,6 +80,7 @@ services:
|
|||
# Dev mode
|
||||
- ${PWD}/packages/worker/src:/app/packages/worker/src
|
||||
# Production mode
|
||||
- /:/host/root:ro
|
||||
- /proc:/host/proc:ro
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
- ${PWD}/.env:/app/.env
|
||||
|
|
|
@ -76,6 +76,7 @@ services:
|
|||
environment:
|
||||
NODE_ENV: production
|
||||
volumes:
|
||||
- /:/host/root:ro
|
||||
- /proc:/host/proc
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
- ${PWD}/.env:/app/.env
|
||||
|
|
|
@ -78,6 +78,7 @@ services:
|
|||
NODE_ENV: production
|
||||
volumes:
|
||||
# Core
|
||||
- /:/host/root:ro
|
||||
- /proc:/host/proc
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
# App
|
||||
|
|
|
@ -36,7 +36,8 @@ export class SystemExecutors {
|
|||
this.logger.error(`Unable to read /host/proc/meminfo: ${e}`);
|
||||
}
|
||||
|
||||
const [disk0] = await si.fsSize();
|
||||
const disks = await si.fsSize();
|
||||
const disk0 = disks.find((disk) => disk.mount.startsWith('/host/root'));
|
||||
|
||||
return {
|
||||
cpu: { load: currentLoad },
|
||||
|
|
Loading…
Reference in a new issue