2018-03-06 05:59:40 -05:00
|
|
|
#!/bin/sh
|
|
|
|
|
2020-02-19 06:06:28 -05:00
|
|
|
# add the node user to the docker group on the host
|
2019-04-21 19:38:24 -04:00
|
|
|
DOCKER_GROUP=$(stat -c '%g' /var/run/docker.sock)
|
|
|
|
groupadd --non-unique --gid ${DOCKER_GROUP} dockeronhost
|
|
|
|
usermod -aG dockeronhost node
|
2018-03-16 13:30:11 -04:00
|
|
|
|
2020-02-19 06:06:28 -05:00
|
|
|
# compatibility: initial volume setup
|
2022-01-06 10:02:36 -05:00
|
|
|
mkdir -p /overleaf/services/clsi/cache && chown node:node /overleaf/services/clsi/cache
|
|
|
|
mkdir -p /overleaf/services/clsi/compiles && chown node:node /overleaf/services/clsi/compiles
|
|
|
|
mkdir -p /overleaf/services/clsi/db && chown node:node /overleaf/services/clsi/db
|
|
|
|
mkdir -p /overleaf/services/clsi/output && chown node:node /overleaf/services/clsi/output
|
2018-03-16 13:30:11 -04:00
|
|
|
|
2019-01-15 06:29:04 -05:00
|
|
|
exec runuser -u node -- "$@"
|