summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-01-05 17:09:26 +0100
committerHugo Hörnquist <hugo@lysator.liu.se>2022-01-05 17:09:55 +0100
commit0ce54eec24a1f06638959e80a5480998cedad169 (patch)
tree71c28369ab5aa80b8d1af0c26cf076491fbfb93f /manifests
parentMove remaining out of site.pp. (diff)
downloadprofiles-0ce54eec24a1f06638959e80a5480998cedad169.tar.gz
profiles-0ce54eec24a1f06638959e80a5480998cedad169.tar.xz
puppetboard letsencrypt.
Diffstat (limited to 'manifests')
-rw-r--r--manifests/puppetboard.pp14
1 files changed, 14 insertions, 0 deletions
diff --git a/manifests/puppetboard.pp b/manifests/puppetboard.pp
index 6262d65..a4cef20 100644
--- a/manifests/puppetboard.pp
+++ b/manifests/puppetboard.pp
@@ -32,6 +32,20 @@ class profiles::puppetboard {
offline_mode => true,
}
+ include ::letsencrypt
+
+ ensure_packages(['python3-certbot-apache'])
+
+ $certname = lookup('certname')
+ letsencrypt::certonly { $certname:
+ ensure => present,
+ domains => [ $::fqdn, ],
+ manage_cron => true,
+ plugin => 'apache',
+ additional_args => ['--quiet'],
+ post_hook_commands => ['systemctl restart apache2'],
+ }
+
class { 'puppetboard::apache::vhost':
vhost_name => $::fqdn,
port => 80,