chore(ops): write the deploy plan before truncating it

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
zacharyandClaude Opus 5 committed 2026-10-08 00:24:40 +02:00
1 parent a2a5af4078
commit 04ef6e2a4a
1 file changed
+4 -1
+4 -1
View File
@@ -117,7 +117,10 @@ if [ -n "$DRY_RUN" ]; then
rsync -ain --delete --rsync-path="sudo rsync" \
--exclude 'run.sh' --exclude 'entrypoint.sh' \
--exclude 'nginx.conf' --exclude 'redis.conf' \
"$STAGE/" "$HOST:$REMOTE_DIR/" | tee /tmp/homarr-deploy-plan.txt | head -30
"$STAGE/" "$HOST:$REMOTE_DIR/" > /tmp/homarr-deploy-plan.txt
# Écrit d'abord, tronqué ensuite : un `| head` ferme le tuyau et rsync s'arrête
# sur SIGPIPE au bout de trente lignes, ce qui donnerait un plan mensonger.
head -30 /tmp/homarr-deploy-plan.txt
echo
echo "$(grep -c '^\*deleting' /tmp/homarr-deploy-plan.txt) suppressions, \
$(grep -vc '^\*deleting' /tmp/homarr-deploy-plan.txt) écritures. Plan complet : /tmp/homarr-deploy-plan.txt"