]>
git.immae.eu Git - github/Chocobozzz/PeerTube.git/blob - support/docker/production/docker-entrypoint.sh
4 # Populate config directory
5 if [ -z "$(ls -A /config)" ]; then
6 cp /app
/support
/docker
/production
/config
/* /config
9 # Always copy default and custom env configuration file, in cases where new keys were added
10 cp /app
/config
/default.yaml
/config
11 cp /app
/support
/docker
/production
/config
/custom
-environment-variables.yaml
/config
12 find /config
! -user peertube
-exec chown peertube
:peertube
{} \
;
14 # first arg is `-f` or `--some-option`
15 # or first arg is `something.conf`
16 if [ "${1#-}" != "$1" ] || [ "${1%.conf}" != "$1" ]; then
20 # allow the container to be started with `--user`
21 if [ "$1" = 'npm' -a "$(id -u)" = '0' ]; then
22 find /data
! -user peertube
-exec chown peertube
:peertube
{} \
;
23 exec gosu peertube
"$0" "$@"