make sure we're installing composer and npm dependencies
This commit is contained in:
@@ -44,11 +44,5 @@ RUN chown -R www-data:www-data . \
|
||||
# install composer
|
||||
COPY --from=composer:2.6.5 /usr/bin/composer /usr/local/bin/composer
|
||||
|
||||
# copy composer.json to workdir & install dependencies
|
||||
RUN composer install
|
||||
|
||||
# Run NPM build
|
||||
RUN npm install && npm run build
|
||||
|
||||
# Run everything else
|
||||
CMD ["./docker/entrypoint.sh"]
|
||||
|
||||
@@ -8,8 +8,12 @@ if [ ! -f /var/www/app/.env ]; then
|
||||
cp /var/www/app/.env.example /var/www/app/.env
|
||||
fi
|
||||
|
||||
echo "Waiting a second for the database to become available..."
|
||||
sleep 2
|
||||
echo "Installing Composer dependencies..."
|
||||
/usr/local/bin/composer install
|
||||
|
||||
echo "Install NPM dependencies and build frontend..."
|
||||
/usr/bin/npm install
|
||||
/usr/bin/npm run build
|
||||
|
||||
echo "Running migrations..."
|
||||
/usr/local/bin/php /var/www/app/artisan migrate
|
||||
|
||||
Reference in New Issue
Block a user