0
0
mirror of https://github.com/saltstack-formulas/letsencrypt-sh-formula.git synced 2024-11-28 03:28:03 +01:00
letsencrypt-sh-formula/letsencrypt-sh/cron.sls

22 lines
608 B
Plaintext
Raw Normal View History

2016-06-21 00:59:06 +02:00
# -*- coding: utf-8 -*-
# vim: ft=sls
{% from "letsencrypt-sh/map.jinja" import letsencrypt_sh with context %}
{% if letsencrypt_sh.cron_enabled %}
letsencrypt-sh-cron:
cron.present:
- name: {{ letsencrypt_sh.cron_command }}
- user: root
- identifier: letsencrypt-sh-cron
- minute: {{ letsencrypt_sh.cron_minute }}
- hour: {{ letsencrypt_sh.cron_hour }}
- dayweek: {{ letsencrypt_sh.cron_dayweek }}
- comment: Renew TLS certificates with letsencrypt.org
{% else %}
disable-letsencrypt-sh-cron:
cron.absent:
- user: root
- identifier: letsencrypt-sh-cron
{% endif %}