From 7089e7b4e570710acac408bf95c688932a491707 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 5 Dec 2018 17:44:36 +0100 Subject: Improve information regarding prune storage script --- scripts/prune-storage.ts | 1 + support/doc/tools.md | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/prune-storage.ts b/scripts/prune-storage.ts index 4ab0b4863..c0cd198f7 100755 --- a/scripts/prune-storage.ts +++ b/scripts/prune-storage.ts @@ -91,6 +91,7 @@ async function askConfirmation () { confirm: { type: 'string', description: 'These following unused files can be deleted, but please check your backups first (bugs happen).' + + ' Notice PeerTube must have been stopped when your ran this script.' + ' Can we delete these files?', default: 'n', required: true diff --git a/support/doc/tools.md b/support/doc/tools.md index 69d68464a..4f806a9db 100644 --- a/support/doc/tools.md +++ b/support/doc/tools.md @@ -198,10 +198,10 @@ $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production ### prune-storage.js Some transcoded videos or shutdown at a bad time can leave some unused files on your storage. -To delete them (a confirmation will be demanded first): +Stop PeerTube and delete these files (a confirmation will be demanded first): ``` -$ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run prune-storage +$ sudo systemctl stop peertube && sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run prune-storage ``` ### optimize-old-videos.js -- cgit v1.2.3