added docker-compose file for production

This commit is contained in:
DigitalInfinity committed 2026-07-02 20:22:24 +00:00
1 parent ec6d7e2a80
commit b532c51c32
5 files changed
+172

No files matched your search

+12
View File
@@ -0,0 +1,12 @@
<VirtualHost *:80>
DocumentRoot /var/www/html/public
<Directory /var/www/html/public>
Options -Indexes +FollowSymLinks
AllowOverride All
Require all granted
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
+23
View File
@@ -0,0 +1,23 @@
#!/bin/sh
set -e
cd /var/www/html
mkdir -p storage/app storage/framework/cache storage/framework/sessions storage/framework/views storage/logs bootstrap/cache
chown -R www-data:www-data storage bootstrap/cache
if [ -n "$DB_DATABASE" ] && [ "$DB_CONNECTION" = "sqlite" ]; then
mkdir -p "$(dirname "$DB_DATABASE")"
touch -a "$DB_DATABASE"
chown www-data:www-data "$DB_DATABASE"
fi
# Only the web process runs bootstrap steps, so the queue/scheduler
# containers (which override CMD) don't race each other on migrations.
if [ "$1" = "apache2-foreground" ]; then
php artisan config:clear
php artisan migrate --force
php artisan storage:link || true
fi
exec "$@"