fix: deploy
Some checks failed
Deploy / deploy (push) Failing after 56s

This commit is contained in:
ext.jeremy.guillot@maxicoffee.domains
2026-03-10 23:14:16 +01:00
parent 08e005a0d3
commit 944994b7d7

View File

@@ -26,15 +26,17 @@ task('deploy:prepare_dirs', function () {
});
// composer install via container éphémère (pas de PHP sur l'hôte requis)
// --user assure que vendor/ appartient au user deploy et non root
task('deploy:vendors', function () {
run('docker run --rm -v {{release_path}}:/app -w /app composer:2 install {{composer_options}}');
run('docker run --rm --user $(id -u):$(id -g) -v {{release_path}}:/app -w /app composer:2 install {{composer_options}}');
});
// Build assets via container node éphémère
// --user assure que public/build/ appartient au user deploy et non root
// mangarr_node_modules volume = cache npm entre les déploiements
desc('Build Webpack Encore assets');
task('webpack_encore:build', function () {
run('docker run --rm -v {{release_path}}:/app -v mangarr_node_modules:/app/node_modules -w /app node:22-alpine sh -c "npm install && npm run build"');
run('docker run --rm --user $(id -u):$(id -g) -v {{release_path}}:/app -v mangarr_node_modules:/app/node_modules -w /app node:22-alpine sh -c "npm install && npm run build"');
});
// Restart Docker containers (entrypoint gère les migrations automatiquement)