2023-06-18 10:50:36 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
export USER=opengist
|
2023-06-21 15:52:18 +00:00
|
|
|
UID=${UID:-1000}
|
2023-06-18 10:50:36 +00:00
|
|
|
GID=${GID:-1000}
|
|
|
|
groupmod -o -g "$GID" $USER
|
2023-06-21 15:52:18 +00:00
|
|
|
usermod -o -u "$UID" $USER
|
2023-06-18 10:50:36 +00:00
|
|
|
|
|
|
|
chown -R "$USER:$USER" /opengist
|
2023-10-15 06:14:34 +00:00
|
|
|
chown -R "$USER:$USER" /config.yml
|
2023-06-18 10:50:36 +00:00
|
|
|
|
2024-09-27 23:31:18 +00:00
|
|
|
if [ -f "/run/secrets/opengist_secrets" ]; then
|
|
|
|
set -a
|
|
|
|
. /run/secrets/opengist_secrets
|
|
|
|
set +a
|
|
|
|
fi
|
|
|
|
|
2023-10-15 06:14:34 +00:00
|
|
|
exec su $USER -c "OG_OPENGIST_HOME=/opengist /app/opengist/opengist --config /config.yml"
|