Do no use scripts in composer i

This commit is contained in:
David Bomba
2023-07-07 16:29:57 +10:00
parent bca8404f5f
commit 4fd6ca33c8
2 changed files with 13 additions and 12 deletions

View File

@@ -49,6 +49,16 @@ RUN mv /usr/local/etc/php/php.ini-production /usr/local/etc/php/php.ini
# https://hub.docker.com/r/mlocati/php-extension-installer/tags
COPY --from=mlocati/php-extension-installer /usr/bin/install-php-extensions /usr/local/bin/
# Install chromium
RUN set -eux; \
apk add --no-cache \
font-isas-misc \
supervisor \
mysql-client \
git \
chromium \
ttf-freefont
RUN install-php-extensions \
bcmath \
exif \
@@ -61,16 +71,6 @@ RUN install-php-extensions \
@composer \
&& rm /usr/local/bin/install-php-extensions
# Install chromium
RUN set -eux; \
apk add --no-cache \
font-isas-misc \
supervisor \
mysql-client \
git \
chromium \
ttf-freefont
# Copy files
COPY rootfs /
@@ -100,7 +100,7 @@ WORKDIR /var/www/app
# Do not remove this ENV
ENV IS_DOCKER true
RUN /usr/local/bin/composer install --no-dev --no-scripts
RUN /usr/local/bin/composer install --no-dev --no-scripts --no-interaction --no-autoloader
# Override the environment settings from projects .env file
ENV APP_ENV production

View File

@@ -24,7 +24,7 @@ docker_process_init_files() {
echo
done
}
php artisan package:discover --ansi
php artisan config:cache
php artisan optimize
php artisan ninja:react
@@ -36,6 +36,7 @@ if [ "$DB_READY" != "1" ]; then
in_error "Error connecting to DB"
fi
composer dump-autoload
php artisan migrate --force
# If first IN run, it needs to be initialized