mirror of
https://github.com/BillyOutlast/UNIT3D-Docker.git
synced 2026-07-01 08:11:44 -04:00
Rebuild alpha 1
This commit is contained in:
Submodule
+1
Submodule UNIT3D added at b4d94a5481
+1
-2
@@ -1,5 +1,3 @@
|
||||
version: '3.8'
|
||||
|
||||
services:
|
||||
unit3d:
|
||||
image: unit3d:latest
|
||||
@@ -11,6 +9,7 @@ services:
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- ./UNIT3D:/var/www/html
|
||||
- ./unit3d.conf:/etc/nginx/conf.d/unit3d.conf
|
||||
env_file:
|
||||
- .env
|
||||
entrypoint: /entrypoint.sh
|
||||
|
||||
+5
-1
@@ -5,10 +5,14 @@ if [[ "$1" == "setup" ]]; then
|
||||
# Run setup commands here
|
||||
cd /var/www/html
|
||||
composer install --no-interaction --prefer-dist
|
||||
php artisan key:generate --show
|
||||
php artisan key:generate
|
||||
echo "Please save this to APP_KEY in UNIT3D/.env"
|
||||
fi
|
||||
if [[ "$1" == "debug" ]]; then
|
||||
echo "Debug mode: keeping container running..."
|
||||
tail -f /dev/null
|
||||
fi
|
||||
if [[ -z "$1" ]]; then
|
||||
echo "Starting Nginx with /etc/nginx/conf.d/unit3d.conf..."
|
||||
nginx -c /etc/nginx/conf.d/unit3d.conf
|
||||
fi
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
server {
|
||||
listen 80;
|
||||
server_name localhost;
|
||||
|
||||
root /var/www/html/public;
|
||||
index index.php index.html index.htm;
|
||||
|
||||
location / {
|
||||
try_files $uri $uri/ /index.php?$query_string;
|
||||
}
|
||||
|
||||
location ~ \.php$ {
|
||||
fastcgi_pass unit:9000;
|
||||
fastcgi_index index.php;
|
||||
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
||||
include fastcgi_params;
|
||||
}
|
||||
|
||||
location ~* \.(jpg|jpeg|png|gif|ico|css|js|svg)$ {
|
||||
expires 30d;
|
||||
access_log off;
|
||||
}
|
||||
|
||||
location ~ /\.ht {
|
||||
deny all;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user