Files
NextChair/docker/entrypoint.sh
T
2026-09-05 09:31:41 +01:00

25 lines
479 B
Bash

#!/bin/sh
set -eu
cd /var/www/html
mkdir -p \
storage/framework/cache/data \
storage/framework/sessions \
storage/framework/views \
storage/logs \
bootstrap/cache
chown -R www-data:www-data storage bootstrap/cache
chmod -R ug+rwX storage bootstrap/cache
# This is safe to run on every start and does not perform migrations.
php artisan storage:link --force >/dev/null 2>&1 || true
if [ "$(id -u)" = "0" ]; then
exec gosu www-data "$@"
fi
exec "$@"