From 43eee692480fa5de7dc725088abd83aa83103180 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Veikko=20Lintuj=C3=A4rvi?= Date: Wed, 2 Sep 2026 21:30:18 +0300 Subject: [PATCH] Add sudo to pm2 commands --- scripts/deploy.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/deploy.sh b/scripts/deploy.sh index 3bca145..6cb954d 100644 --- a/scripts/deploy.sh +++ b/scripts/deploy.sh @@ -19,11 +19,11 @@ sudo bun run build echo "Starting/reloading with pm2..." if pm2 describe "$APP_NAME" > /dev/null 2>&1; then - pm2 reload "$APP_NAME" --update-env + sudo pm2 reload "$APP_NAME" --update-env else - pm2 start bun --name "$APP_NAME" -- run start + sudo pm2 start bun --name "$APP_NAME" -- run start fi -pm2 save +sudo pm2 save echo "Deployment complete."