mirror of
https://github.com/DanWin/mail-hosting.git
synced 2024-11-24 00:20:26 +00:00
add mail-cron systemd unit
This commit is contained in:
parent
46a76764ad
commit
e8f64f6913
2 changed files with 22 additions and 0 deletions
8
etc/systemd/system/mail-cron.service
Normal file
8
etc/systemd/system/mail-cron.service
Normal file
|
@ -0,0 +1,8 @@
|
|||
[Unit]
|
||||
Description=Mail cron
|
||||
After=srv.mount
|
||||
Requires=srv.mount
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/usr/bin/php /srv/var/www/mail/cron.php
|
14
etc/systemd/system/mail-cron.timer
Normal file
14
etc/systemd/system/mail-cron.timer
Normal file
|
@ -0,0 +1,14 @@
|
|||
[Unit]
|
||||
Description=Mail cron
|
||||
After=srv.mount
|
||||
Requires=srv.mount
|
||||
|
||||
[Timer]
|
||||
# Time to wait after booting before we run first time
|
||||
OnBootSec=3min
|
||||
# Time between running each consecutive time
|
||||
OnUnitActiveSec=5m
|
||||
Unit=mail-cron.service
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Reference in a new issue