kimai-container/s6-rc.d/kimai-install/script.sh
2023-02-02 14:30:05 -03:00

11 lines
346 B
Bash
Executable file

#!/bin/sh
while test ! -S /run/mysqld/mysqld.sock; do sleep 1; done
if test "$APP_SECRET" = change_this_to_something_unique; then
echo "No APP_SECRET"
exit 1
fi
echo "APP_SECRET='$APP_SECRET'" >> /opt/kimai/.env
su nobody -c 'console kimai:install --no-interaction' || exit $?
su nobody -c 'console kimai:update --no-interaction' || exit $?