This commit is contained in:
Andras Bacsai 2023-06-15 11:02:37 +02:00
parent 38cb3fddd9
commit 1540493b29

View File

@ -4,8 +4,7 @@ WORKDIR /var/www/html
COPY composer.json composer.lock ./
RUN composer install --no-dev --no-interaction --no-plugins --no-scripts --prefer-dist
COPY --chown=9999:9999 . .
RUN composer dump-autoload
FROM node:19 as static-assets
WORKDIR /app
@ -23,10 +22,15 @@ RUN apt-get -y autoremove && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/*
COPY docker/prod-ssu/nginx.conf /etc/nginx/conf.d/custom.conf
COPY --from=base --chown=9999:9999 /var/www/html .
COPY --chown=9999:9999 . .
RUN composer dump-autoload
COPY --from=static-assets --chown=9999:9999 /app/public/build ./public/build
COPY --chmod=755 docker/prod-ssu/etc/s6-overlay/ /etc/s6-overlay/
RUN php artisan optimize
RUN php artisan route:cache
RUN php artisan view:cache
RUN echo "alias ll='ls -al'" >>/etc/bash.bashrc
RUN echo "alias a='php artisan'" >>/etc/bash.bashrc