feat(docker): prod, fix misc

This commit is contained in:
Michael 2025-06-05 14:01:12 +02:00
parent 734f4b90db
commit d8d293ea7c

View file

@ -422,26 +422,21 @@ RUN chown $sintonia_user:$sintonia_user /home/$sintonia_user/.env
USER $sintonia_user
WORKDIR /var/www/sintonia_webapp
RUN git clone --branch dev --single-branch https://git.congegni.net/Congegni/sintonia_webapp . && \
CMD git clone --branch dev --single-branch https://git.congegni.net/Congegni/sintonia_webapp . && \
cp /home/$sintonia_user/.env /var/www/sintonia_webapp && \
/home/$sintonia_user/composer install --no-progress --no-interaction && \
/home/$sintonia_user/composer --no-cache dump-autoload --no-interaction
RUN php artisan key:generate
RUN php artisan migrate
RUN php artisan db:seed && \
/home/$sintonia_user/composer --no-cache dump-autoload --no-interaction && \
rm -rf /var/www/sintonia_webapp/node_modules /var/www/sintonia_webapp/.npm /var/www/sintonia_webapp/.composer /var/www/sintonia_webapp/.git && \
rm -rf /home/$sintonia_user/node* /home/$sintonia_user/composer && \
php artisan key:generate && \
php artisan migrate && \
php artisan db:seed && \
php artisan schedule:run >> /dev/null 2>&1 && \
set -eux && \
npm i && \
npm run build
RUN rm -rf /var/www/sintonia_webapp/node_modules /var/www/sintonia_webapp/.npm /var/www/sintonia_webapp/.composer /var/www/sintonia_webapp/.git && \
rm -rf /home/$sintonia_user/node* /home/$sintonia_user/composer
RUN cron && \
npm run build && \
cron && \
php-fpm -D && \
php artisan schedule:run >> /dev/null 2>&1 && \
sleep infinity