Install actual on Raspberry Pi
This commit is contained in:
parent
64fa1562dd
commit
6c0425418e
9 changed files with 109 additions and 8 deletions
|
|
@ -3,3 +3,8 @@
|
|||
become: true
|
||||
ansible.builtin.command:
|
||||
cmd: snap set certbot trust-plugin-with-root=ok
|
||||
- name: Restart Nginx
|
||||
become: true
|
||||
ansible.builtin.systemd:
|
||||
name: nginx.service
|
||||
state: restarted
|
||||
|
|
|
|||
|
|
@ -19,8 +19,12 @@
|
|||
ansible.builtin.apt:
|
||||
name: nginx # Creates the "nginx" user as well
|
||||
state: present
|
||||
# TODO: Remove the default configuration here, we'll keep it for now as an example...
|
||||
# TODO: Setup Certbot as it's part of the installation...
|
||||
- name: Remove default configuration
|
||||
become: true
|
||||
ansible.builtin.file:
|
||||
path: /etc/nginx/conf.d/default.conf
|
||||
state: absent
|
||||
notify: Restart Nginx
|
||||
# ---------- CERTBOT INSTALLATION ---------- #
|
||||
# See the installation instructions here: https://certbot.eff.org/instructions?ws=nginx&os=debianbuster&tab=wildcard
|
||||
- name: Install Certbot
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
#!/bin/bash
|
||||
/snap/bin/certbot certonly \
|
||||
--dns-cloudflare \
|
||||
--dns-cloudflare-propagation-seconds 120 \
|
||||
--dns-cloudflare-credentials '{{ cloudflare_credential_dir_path }}/{{ cloudflare_credential_filename }}' \
|
||||
--agree-tos --test-cert -m {{ administration_email }} \
|
||||
--agree-tos -m {{ administration_email }} \
|
||||
-d $1
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue