mirror of
https://github.com/invoiceninja/dockerfiles.git
synced 2026-01-18 12:24:09 +01:00
Compare commits
12 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c729ef8a48 | ||
|
|
59232e8d22 | ||
|
|
814dd175c7 | ||
|
|
06f723d7dc | ||
|
|
b599ca5905 | ||
|
|
d222163f82 | ||
|
|
d81eb48e55 | ||
|
|
a7f9ed049c | ||
|
|
aec886c9eb | ||
|
|
84efa573f0 | ||
|
|
849fc2365d | ||
|
|
adfa143861 |
1
debian/php/php.ini
vendored
1
debian/php/php.ini
vendored
@@ -2,6 +2,7 @@
|
|||||||
; https://www.php.net/manual/en/ini.core.php
|
; https://www.php.net/manual/en/ini.core.php
|
||||||
post_max_size=10M
|
post_max_size=10M
|
||||||
upload_max_filesize=10M
|
upload_max_filesize=10M
|
||||||
|
memory_limit=512M
|
||||||
|
|
||||||
[opcache]
|
[opcache]
|
||||||
; https://www.php.net/manual/en/opcache.installation.php#opcache.installation.recommended
|
; https://www.php.net/manual/en/opcache.installation.php#opcache.installation.recommended
|
||||||
|
|||||||
13
debian/scripts/init.sh
vendored
13
debian/scripts/init.sh
vendored
@@ -10,6 +10,7 @@ fi
|
|||||||
if [ "$*" = 'supervisord -c /etc/supervisor/supervisord.conf' ]; then
|
if [ "$*" = 'supervisord -c /etc/supervisor/supervisord.conf' ]; then
|
||||||
|
|
||||||
# Check for required folders and create if needed
|
# Check for required folders and create if needed
|
||||||
|
[ -d /var/www/html/public ] || mkdir -p /var/www/html/public
|
||||||
[ -d /var/www/html/storage/app/public ] || mkdir -p /var/www/html/storage/app/public
|
[ -d /var/www/html/storage/app/public ] || mkdir -p /var/www/html/storage/app/public
|
||||||
[ -d /var/www/html/storage/framework/sessions ] || mkdir -p /var/www/html/storage/framework/sessions
|
[ -d /var/www/html/storage/framework/sessions ] || mkdir -p /var/www/html/storage/framework/sessions
|
||||||
[ -d /var/www/html/storage/framework/views ] || mkdir -p /var/www/html/storage/framework/views
|
[ -d /var/www/html/storage/framework/views ] || mkdir -p /var/www/html/storage/framework/views
|
||||||
@@ -21,10 +22,14 @@ if [ "$*" = 'supervisord -c /etc/supervisor/supervisord.conf' ]; then
|
|||||||
rm -rf /var/www/html/public/.htaccess \
|
rm -rf /var/www/html/public/.htaccess \
|
||||||
/var/www/html/public/.well-known \
|
/var/www/html/public/.well-known \
|
||||||
/var/www/html/public/*
|
/var/www/html/public/*
|
||||||
mv /tmp/public/* \
|
cp -r /tmp/public/* \
|
||||||
/tmp/public/.htaccess \
|
/tmp/public/.htaccess \
|
||||||
/tmp/public/.well-known \
|
/tmp/public/.well-known \
|
||||||
/var/www/html/public/
|
/var/www/html/public/ &&
|
||||||
|
rm -rf /tmp/public/.htaccess \
|
||||||
|
/tmp/public/.well-known \
|
||||||
|
/tmp/public/*
|
||||||
|
|
||||||
fi
|
fi
|
||||||
echo "Public Folder is up to date"
|
echo "Public Folder is up to date"
|
||||||
|
|
||||||
@@ -41,7 +46,7 @@ if [ "$*" = 'supervisord -c /etc/supervisor/supervisord.conf' ]; then
|
|||||||
|
|
||||||
# Clear and cache config in production
|
# Clear and cache config in production
|
||||||
if [ "$APP_ENV" = "production" ]; then
|
if [ "$APP_ENV" = "production" ]; then
|
||||||
runuser -u www-data -- php artisan migrate --force
|
runuser -u www-data -- php artisan migrate --force
|
||||||
runuser -u www-data -- php artisan cache:clear # Clear after the migration
|
runuser -u www-data -- php artisan cache:clear # Clear after the migration
|
||||||
runuser -u www-data -- php artisan ninja:design-update
|
runuser -u www-data -- php artisan ninja:design-update
|
||||||
runuser -u www-data -- php artisan optimize
|
runuser -u www-data -- php artisan optimize
|
||||||
@@ -49,7 +54,7 @@ if [ "$*" = 'supervisord -c /etc/supervisor/supervisord.conf' ]; then
|
|||||||
# If first IN run, it needs to be initialized
|
# If first IN run, it needs to be initialized
|
||||||
if [ "$(runuser -u www-data -- php artisan tinker --execute='echo Schema::hasTable("accounts") && !App\Models\Account::all()->first();')" = "1" ]; then
|
if [ "$(runuser -u www-data -- php artisan tinker --execute='echo Schema::hasTable("accounts") && !App\Models\Account::all()->first();')" = "1" ]; then
|
||||||
echo "Running initialization..."
|
echo "Running initialization..."
|
||||||
|
|
||||||
runuser -u www-data -- php artisan db:seed --force
|
runuser -u www-data -- php artisan db:seed --force
|
||||||
|
|
||||||
if [ -n "${IN_USER_EMAIL}" ] && [ -n "${IN_PASSWORD}" ]; then
|
if [ -n "${IN_USER_EMAIL}" ] && [ -n "${IN_PASSWORD}" ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user