caddy: make plugin list configureable (fixes #4)

This commit is contained in:
Jannik Beyerstedt 2020-05-24 17:08:11 +02:00
parent 3720b6bf73
commit 06cd3d3076
4 changed files with 8 additions and 4 deletions

View file

@ -33,6 +33,9 @@ Attention: You still need to setup the borgbackup repository manually.
Mandatory variable:
- `caddy_email`: Email address to use for getting let's encrypt certificates
Optional variable:
- `caddy_plugins`: Comma separated list of caddyserver v1 plugins (default: `http.ratelimit`)
### Cronmails
Mandatory variable:
- `cron_email`: Sender email address used by cron

View file

@ -4,6 +4,7 @@
borgbackup_ssh_id: "{{ ansible_user_dir }}/.ssh/id_ed25519"
caddy_cachedir: "{{ ansible_user_dir }}/.ansbl-caddy-cache"
caddy_plugins: "http.ratelimit"
telegraf_interval: "300s"
telegraf_docker_file: "telegraf-docker.conf"

View file

@ -22,17 +22,17 @@
- name: caddyserver - Download caddy webserver (amd64)
get_url:
url: "https://caddyserver.com/download/linux/amd64?plugins=http.ratelimit&license=personal"
url: "https://caddyserver.com/download/linux/amd64?plugins={{ caddy_plugins }}&license=personal"
dest: "{{ caddy_cachedir }}/tmp/caddy.tar.gz"
when: ansible_architecture == "x86_64"
- name: caddyserver - Download caddy webserver (armv7/ raspberry pi)
get_url:
url: "https://caddyserver.com/download/linux/arm7?plugins=http.ratelimit&license=personal"
url: "https://caddyserver.com/download/linux/arm7?plugins={{ caddy_plugins }}&license=personal"
dest: "{{ caddy_cachedir }}/tmp/caddy.tar.gz"
when: ansible_architecture == "armv7l"
- name: caddyserver - Download caddy webserver (arm64)
get_url:
url: "https://caddyserver.com/download/linux/arm64?plugins=http.ratelimit&license=personal"
url: "https://caddyserver.com/download/linux/arm64?plugins={{ caddy_plugins }}&license=personal"
dest: "{{ caddy_cachedir }}/tmp/caddy.tar.gz"
when: ansible_architecture == "aarch64"

View file

@ -34,7 +34,7 @@
repo: "deb [arch={{ dpkg_arch.stdout }}] https://download.docker.com/linux/debian {{ ansible_distribution_release }} stable"
state: present
when: ansible_facts['lsb']['id'] != "Raspbian"
- name: docker - Add docker CE repo (Rasbian)
- name: docker - Add docker CE repo (Raspbian)
become: yes
apt_repository:
repo: "deb [arch={{ dpkg_arch.stdout }}] https://download.docker.com/linux/raspbian {{ ansible_distribution_release }} stable"