diff options
| author | Ahmed Abdelhalim <[email protected]> | 2026-07-20 16:04:25 +0200 |
|---|---|---|
| committer | Ahmed Abdelhalim <[email protected]> | 2026-07-20 16:22:43 +0200 |
| commit | 9ace460d819b3863fba08e1b757e0f6e5c6d0290 (patch) | |
| tree | 015061a7866b949084f701ca927bb8a2d86de18e /roles/caddy/tasks/install-debian.yml | |
| parent | 43034bba4574f03c5d88f4380767c40e64d60c6e (diff) | |
Update caddy to install latest stable version
Diffstat (limited to 'roles/caddy/tasks/install-debian.yml')
| -rw-r--r-- | roles/caddy/tasks/install-debian.yml | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/roles/caddy/tasks/install-debian.yml b/roles/caddy/tasks/install-debian.yml new file mode 100644 index 00000000..710c9e90 --- /dev/null +++ b/roles/caddy/tasks/install-debian.yml @@ -0,0 +1,24 @@ +--- +- name: "Download Caddy GPG key" + become: true + ansible.builtin.get_url: + url: "https://dl.cloudsmith.io/public/caddy/stable/gpg.key" + dest: "/etc/apt/trusted.gpg.d/caddy-stable.asc" + mode: "0644" + owner: "root" + group: "root" + +- name: "Add Caddy APT repository" + become: true + ansible.builtin.apt_repository: + # yamllint disable-line rule:line-length + repo: "deb [signed-by=/etc/apt/trusted.gpg.d/caddy-stable.asc] https://dl.cloudsmith.io/public/caddy/stable/deb/debian any-version main" + state: "present" + filename: "caddy-stable" + +- name: "Install caddy" + become: true + ansible.builtin.package: + name: "caddy" + state: "present" + update_cache: true |
