Merge pull request #21097 from overleaf/ls-scripts-to-esm-1

Migrate scripts folder to esm 1/x

GitOrigin-RevId: 4a4bc9a161f144fdb40ce3f2a0a9313b36c6df81
This commit is contained in:
Liangjun Song
2024-10-18 19:04:57 +08:00
committed by Copybot
parent 8bc374c916
commit 26f3f3e2e2
94 changed files with 916 additions and 847 deletions

View File

@@ -12,12 +12,12 @@ echo "closed" > "${SITE_MAINTENANCE_FILE}"
sleep 5
# giving a grace period of 5 seconds for users before disconnecting them and start shutting down
cd /overleaf/services/web && node scripts/disconnect_all_users.js --delay-in-seconds=5 >> /var/log/overleaf/web.log 2>&1
cd /overleaf/services/web && node scripts/disconnect_all_users.mjs --delay-in-seconds=5 >> /var/log/overleaf/web.log 2>&1
EXIT_CODE="$?"
if [ $EXIT_CODE -ne 0 ]
then
echo "scripts/disconnect_all_users.js failed with exit code $EXIT_CODE"
echo "scripts/disconnect_all_users.mjs failed with exit code $EXIT_CODE"
exit 1
fi