From 113221a9b2b677a2a65559be00fecb8f71d8a5f4 Mon Sep 17 00:00:00 2001 From: Franziska Kunsmann Date: Sat, 31 Oct 2020 10:18:40 +0100 Subject: [PATCH] bundles/nginx: make sure we have dhparam.pem --- bundles/nginx/items.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/bundles/nginx/items.py b/bundles/nginx/items.py index 20f89d4..9833f83 100644 --- a/bundles/nginx/items.py +++ b/bundles/nginx/items.py @@ -22,9 +22,17 @@ files = { }, } +actions = { + 'nginx-generate-dhparam': { + 'command': 'openssl dhparam -out /etc/ssl/certs/dhparam.pem 2048', + 'unless': 'test -f /etc/ssl/certs/dhparam.pem', + }, +} + svc_systemd = { 'nginx': { 'needs': { + 'action:nginx-generate-dhparam', 'pkg_apt:nginx', }, },