Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F24894596
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/roles/core/certificates/acmesh.sls b/roles/core/certificates/acmesh.sls
index 012b2c4..f56b764 100644
--- a/roles/core/certificates/acmesh.sls
+++ b/roles/core/certificates/acmesh.sls
@@ -1,59 +1,70 @@
# -------------------------------------------------------------
# Salt - Deploy acme.sh
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Nasqueron
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
{% from "map.jinja" import dirs with context %}
{% set certificates = pillar.get("certificates", []) %}
{% set certificates_options = pillar.get("certificates_options", {}) %}
acme.sh:
pkg.installed
/var/certificates:
file.directory:
- user: acme
- mode: 711
/var/certificates/general:
file.directory:
- user: acme
- mode: 700
{% for domain in certificates %}
{% set options = certificates_options.get(domain, {}) %}
/var/certificates/{{ domain }}:
file.directory:
- user: acme
{% if "shared_group" in options %}
- group: {{ options.shared_group }}
- mode: 750
{% else %}
- mode: 700
{% endif %}
+/var/certificates/{{ domain }}/key.pem:
+ file.managed:
+ - create: False
+
+ {% if "shared_group" in options %}
+ - group: {{ options.shared_group }}
+ - mode: 640
+ {% else %}
+ - mode: 600
+ {% endif %}
+
{% endfor %}
/usr/local/etc/newsyslog.conf.d/acme.sh.conf:
file.managed:
- source: salt://roles/core/certificates/files/acmesh/syslog.conf
acmesh_newsyslog_run:
cmd.run:
- name: newsyslog -NC
- creates: /var/log/acme.sh.log
/usr/local/etc/cron.d/acmesh:
file.managed:
- source: salt://roles/core/certificates/files/acmesh/acme.sh.cron
- makedirs: True
{{ dirs.bin }}/acmesh-nginxCheck:
file.managed:
- source: salt://roles/core/certificates/files/acmesh/nginxCheck.sh
- mode: 755
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Wed, Mar 18, 12:59 (1 d, 15 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3539899
Default Alt Text
(1 KB)
Attached To
Mode
rOPS Nasqueron Operations
Attached
Detach File
Event Timeline
Log In to Comment