pr_27504.patch 1.3 KB

12345678910111213141516171819202122232425262728293031323334
  1. diff --git a/bin/flush-history-queues b/bin/flush-history-queues
  2. index b54bc5558c6e..6c0cd896416e 100755
  3. --- a/bin/flush-history-queues
  4. +++ b/bin/flush-history-queues
  5. @@ -5,4 +5,4 @@ set -euo pipefail
  6. source /etc/container_environment.sh
  7. source /etc/overleaf/env.sh
  8. cd /overleaf/services/project-history
  9. -node scripts/flush_all.js 100000
  10. +exec /sbin/setuser www-data node scripts/flush_all.js 100000
  11. diff --git a/bin/force-history-resyncs b/bin/force-history-resyncs
  12. index 389c98a4ad69..4f48890855b7 100755
  13. --- a/bin/force-history-resyncs
  14. +++ b/bin/force-history-resyncs
  15. @@ -5,4 +5,4 @@ set -euo pipefail
  16. source /etc/container_environment.sh
  17. source /etc/overleaf/env.sh
  18. cd /overleaf/services/project-history
  19. -node scripts/force_resync.js 1000 force
  20. +exec /sbin/setuser www-data node scripts/force_resync.js 1000 force
  21. diff --git a/cron/project-history-flush-all.sh b/cron/project-history-flush-all.sh
  22. index 8fe9eea5fc55..689561737914 100755
  23. --- a/cron/project-history-flush-all.sh
  24. +++ b/cron/project-history-flush-all.sh
  25. @@ -9,6 +9,6 @@ date
  26. source /etc/container_environment.sh
  27. source /etc/overleaf/env.sh
  28. -cd /overleaf/services/project-history && node scripts/flush_all.js
  29. +cd /overleaf/services/project-history && /sbin/setuser www-data node scripts/flush_all.js
  30. echo "Done flushing all project-history changes"