File tree Expand file tree Collapse file tree 3 files changed +18
-7
lines changed
Expand file tree Collapse file tree 3 files changed +18
-7
lines changed Original file line number Diff line number Diff line change @@ -7,15 +7,24 @@ cd /app
77if [ -f /app/var/.env ]; then
88 echo " external vars exist"
99 rm /app/.env
10+
1011 ln -s /app/var/.env /app/
1112else
1213 echo " external vars don't exist"
13- php artisan key:generate --force
14- cp /app/.env /app/var/
14+ rm /app/.env
15+ touch /app/var/.env
16+
17+ # # manually generate a key because key generate --force fails
18+ echo -e " Generating key"
19+ APP_KEY=$( cat /dev/urandom | tr -dc ' a-zA-Z0-9' | fold -w 32 | head -n 1)
20+ echo -e " Generated app key: $APP_KEY "
21+ echo -e " APP_KEY=$APP_KEY " > /app/var/.env
22+
23+ ln -s /app/var/.env /app/
1524fi
1625
1726# # check for DB up before starting the panel
18- echo " Checking database status."
27+ zshoecho " Checking database status."
1928until nc -z -v -w30 $DB_HOST 3306
2029
2130do
@@ -32,7 +41,7 @@ echo -e "Done\n"
3241# # start php-fpm in the background
3342echo -e " Starting php-fpm in the background. \n"
3443php-fpm7 -D
35- echo -e " php-fpm starte.d \n"
44+ echo -e " php-fpm started \n"
3645
3746# # start webserver
3847echo -e " Starting nginx in the foreground. \n"
Original file line number Diff line number Diff line change @@ -9,10 +9,10 @@ COPY . ./
99
1010RUN cp .dev/docker/default.conf /etc/nginx/conf.d/default.conf \
1111 && cp .dev/docker/www.conf /etc/php7/php-fpm.d/www.conf \
12- && echo "APP_ENVIRONMENT_ONLY=false" > /app/.env \
13- && echo "APP_KEY=" >> /app/.env \
1412 && mkdir /var/run/php \
15- && composer install --no-dev
13+ && cp .env.example .env \
14+ && composer install --no-dev --optimize-autoloader \
15+ && rm .env
1616
1717EXPOSE 80 443
1818
Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ services:
2323 - cache
2424 volumes :
2525 - " /srv/pterodactyl/var/:/app/var/"
26+ - " /srv/pterodactyl/certs/:/"
2627 environment :
2728 # # These are defaults and should be left alone
2829 - " APP_ENV=production"
@@ -34,6 +35,7 @@ services:
3435 - " QUEUE_HIGH=high"
3536 - " QUEUE_STANDARD=standard"
3637 - " QUEUE_LOW=low"
38+ # # Cache settings
3739 - " CACHE_DRIVER=redis"
3840 - " SESSION_DRIVER=redis"
3941 - " QUEUE_DRIVER=redis"
You can’t perform that action at this time.
0 commit comments