aboutsummaryrefslogtreecommitdiffstats
path: root/roles/obsd_cgit
diff options
context:
space:
mode:
authorEugene Triguba <hello@eugenetriguba.com>2026-10-17 21:23:25 -0700
committerEugene Triguba <hello@eugenetriguba.com>2026-10-17 21:32:44 -0700
commitb686c6ae9ff18ca1ce8b8e602dc03548cbfa7b31 (patch)
tree2bde43d963e2c8703cf7d39443ac0301cbd332a2 /roles/obsd_cgit
parentMove playbook vars to the role that uses them (diff)
downloadsite-configs-b686c6ae9ff18ca1ce8b8e602dc03548cbfa7b31.zip
Add better encapsulation to ansible roles
- Replace a few of the global variables in the host inventory to explicit variables that we pass into the particular roles that need it. - Move slowcgi setup to cgit since that is where it is needed (instead of obsd_httpd) - Rename `acme_client` to `obsd_ssl` to better emphasize it is related to generating ssl certificates on openbsd. - Add support for multiple ssl certificates into `obsd_ssl` by looping over the new role variable it has
Diffstat (limited to 'roles/obsd_cgit')
-rw-r--r--roles/obsd_cgit/handlers/main.yml4
-rw-r--r--roles/obsd_cgit/tasks/main.yml7
2 files changed, 6 insertions, 5 deletions
diff --git a/roles/obsd_cgit/handlers/main.yml b/roles/obsd_cgit/handlers/main.yml
deleted file mode 100644
index 356bdcb..0000000
--- a/roles/obsd_cgit/handlers/main.yml
+++ /dev/null
@@ -1,4 +0,0 @@
-- name: Reload httpd
- ansible.builtin.service:
- name: httpd
- state: reloaded
diff --git a/roles/obsd_cgit/tasks/main.yml b/roles/obsd_cgit/tasks/main.yml
index 1d19d18..59b0e62 100644
--- a/roles/obsd_cgit/tasks/main.yml
+++ b/roles/obsd_cgit/tasks/main.yml
@@ -77,10 +77,15 @@
- name: Compile markdown renderer into chroot
ansible.builtin.include_tasks: markdown.yml
+- name: Enable slowcgi
+ ansible.builtin.service:
+ name: slowcgi
+ enabled: true
+
- name: Deploy cgit vhost fragment
ansible.builtin.template:
src: httpd.d/cgit.conf.j2
- dest: "{{ obsd_httpd_conf_d | default('/etc/httpd.d') }}/cgit.conf"
+ dest: "{{ obsd_httpd_conf_d }}/cgit.conf"
owner: root
group: wheel
mode: "0644"