cleanup modal: list stale files to remove; storage restructure: documents/ → {objet}/

This commit is contained in:
Pontoporeia
2026-05-19 22:00:10 +02:00
parent c6199525f9
commit defc919cd0
19 changed files with 292 additions and 22 deletions

View File

@@ -51,6 +51,9 @@ deploy:
--exclude '.DS_Store' \
--exclude '.env' \
--exclude 'storage/xamxam.db' \
--exclude 'storage/tfe/' \
--exclude 'storage/these/' \
--exclude 'storage/frart/' \
--exclude 'storage/theses' \
--exclude 'storage/covers' \
--exclude 'storage/backup_*' \
@@ -316,6 +319,16 @@ trigger-backup:
# Manually trigger the backup script on the server now (doesn't wait for cron).
ssh -t xamxam "sudo -u www-data /usr/local/bin/backup-sqlite.sh"
[group('deploy')]
deploy-migrate-storage dry_run='' target_host='xamxam':
# Run the storage path migration on the remote server.
# Usage:
# just deploy-migrate-storage # apply migration
# just deploy-migrate-storage --dry-run # dry-run only
rsync -v scripts/migrate-storage-paths.php {{target_host}}:/var/www/xamxam/migrate-storage-paths.php
ssh {{target_host}} 'cd /var/www/xamxam && php migrate-storage-paths.php {{dry_run}}'
ssh {{target_host}} 'rm -f /var/www/xamxam/migrate-storage-paths.php'
[group('deploy')]
deploy-all-first: deploy deploy-backup
# One-shot: full initial deploy including backup cron.