diff --git a/docker/8.4/start-container b/docker/8.4/start-container index 40c55df..dfe9799 100644 --- a/docker/8.4/start-container +++ b/docker/8.4/start-container @@ -15,6 +15,11 @@ fi chmod -R ugo+rw /.composer +# 確保 storage 軟連結存在 +if [ ! -L /var/www/html/public/storage ]; then + php /var/www/html/artisan storage:link +fi + if [ $# -gt 0 ]; then if [ "$SUPERVISOR_PHP_USER" = "root" ]; then exec "$@" diff --git a/docker/8.5/start-container b/docker/8.5/start-container index 40c55df..dfe9799 100644 --- a/docker/8.5/start-container +++ b/docker/8.5/start-container @@ -15,6 +15,11 @@ fi chmod -R ugo+rw /.composer +# 確保 storage 軟連結存在 +if [ ! -L /var/www/html/public/storage ]; then + php /var/www/html/artisan storage:link +fi + if [ $# -gt 0 ]; then if [ "$SUPERVISOR_PHP_USER" = "root" ]; then exec "$@"