diff options
author | Trygve Laugstøl <trygvis@inamo.no> | 2018-08-14 22:19:57 +0200 |
---|---|---|
committer | Trygve Laugstøl <trygvis@inamo.no> | 2018-08-14 22:19:57 +0200 |
commit | 44a97f1844b5addb7a6ee3d9b27997d27dee9661 (patch) | |
tree | 04cbea886717c3e2ecb8e047a02415157c59f336 /ansible/roles/mw-backend/files | |
parent | 08871b8c43e14097a5b9572f4125e6a47b60c06a (diff) | |
download | infra-44a97f1844b5addb7a6ee3d9b27997d27dee9661.tar.gz infra-44a97f1844b5addb7a6ee3d9b27997d27dee9661.tar.bz2 infra-44a97f1844b5addb7a6ee3d9b27997d27dee9661.tar.xz infra-44a97f1844b5addb7a6ee3d9b27997d27dee9661.zip |
mw-backend: Creating timer for running runJobs.php.
Diffstat (limited to 'ansible/roles/mw-backend/files')
-rw-r--r-- | ansible/roles/mw-backend/files/etc/systemd/system/mw-jobqueue.service | 12 | ||||
-rw-r--r-- | ansible/roles/mw-backend/files/etc/systemd/system/mw-jobqueue.timer | 9 |
2 files changed, 21 insertions, 0 deletions
diff --git a/ansible/roles/mw-backend/files/etc/systemd/system/mw-jobqueue.service b/ansible/roles/mw-backend/files/etc/systemd/system/mw-jobqueue.service new file mode 100644 index 0000000..a944443 --- /dev/null +++ b/ansible/roles/mw-backend/files/etc/systemd/system/mw-jobqueue.service @@ -0,0 +1,12 @@ +[Unit] +Description=MediaWiki Job runner + +[Service] +WorkingDirectory=/var/lib/mediawiki/maintenance +ExecStart=/usr/bin/php runJobs.php --maxjobs 100 +User=www-data +Group=www-data +StandardOutput=journal + +Nice=10 +OOMScoreAdjust=500 diff --git a/ansible/roles/mw-backend/files/etc/systemd/system/mw-jobqueue.timer b/ansible/roles/mw-backend/files/etc/systemd/system/mw-jobqueue.timer new file mode 100644 index 0000000..1d12500 --- /dev/null +++ b/ansible/roles/mw-backend/files/etc/systemd/system/mw-jobqueue.timer @@ -0,0 +1,9 @@ +[Unit] +Description=MediaWiki job runner timer + +[Timer] +OnBootSec=15min +OnUnitActiveSec=10m + +[Install] +WantedBy=timers.target |