Skip to content

Commit 3191979

Browse files
authored
Merge pull request #20 from sourceboat/feature/fix-entrypoint-2
Fix Dockerfile entrypoint and change dir before run artisan in entrypoint.sh
2 parents f799dbf + 53f8a01 commit 3191979

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,6 @@ RUN find /home/app -name "run-*.sh" -exec chmod -v +x {} \;
110110
RUN chmod +x /home/app/entrypoint.sh
111111

112112
# run the application
113-
ENTRYPOINT bash /home/app/entrypoint.sh
113+
ENTRYPOINT ["/home/app/entrypoint.sh"]
114114
CMD /home/app/run-prod.sh
115115
EXPOSE 8080

home/app/entrypoint.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@ touch /opt/app/storage/logs/worker.log
1010
chown www-data:www-data -R /opt/app/storage
1111
chown www-data:www-data -R /opt/app/bootstrap/cache
1212

13+
cd /opt/app
14+
1315
# create storage symlink
1416
echo "create storage symlink..."
1517
su www-data -s /bin/sh -c "php artisan storage:link -q"
1618

1719
# startup commands
1820
php /usr/local/bin/startup-commands.php | bash
1921

20-
cd /opt/app
21-
22-
"$@"
22+
exec "$@"

0 commit comments

Comments
 (0)