aboutsummaryrefslogtreecommitdiffstats
path: root/tasks/jail_homepage.yml
diff options
context:
space:
mode:
authorJan Tuomi <jan@jantuomi.fi>2026-05-13 00:13:57 +0300
committerJan Tuomi <jan@jantuomi.fi>2026-05-16 18:42:27 +0300
commitb5860daf11ac353049cb1654b9414a129e5cfb96 (patch)
tree87ed89711e4f0e85ace0a97fa123199152c67302 /tasks/jail_homepage.yml
parent4715a28fdcd87440400d17154bfa361d99db29cc (diff)
Rework
Diffstat (limited to 'tasks/jail_homepage.yml')
-rw-r--r--tasks/jail_homepage.yml52
1 files changed, 0 insertions, 52 deletions
diff --git a/tasks/jail_homepage.yml b/tasks/jail_homepage.yml
deleted file mode 100644
index 6751ad5..0000000
--- a/tasks/jail_homepage.yml
+++ /dev/null
@@ -1,52 +0,0 @@
-- name: Install packages inside jail
- loop:
- - { jail: homepage, package: nginx }
- - { jail: homepage, package: rsync }
- - { jail: homepage, package: bash }
- include_tasks: pkg_jail_install.yml
-
-- name: Create /var/www
- file:
- path: /usr/local/jails/containers/homepage/var/www
- state: directory
- owner: www
- group: www
- mode: "0755"
-
-# It's important to run this after generating certs, because nginx.conf refers to files
-# generated by certbot. Certbot will fail validation if nginx.conf is configured too early.
-- name: Configure nginx.conf
- template:
- src: homepage/usr_local_etc_nginx_nginx.conf.j2
- dest: /usr/local/jails/containers/homepage/usr/local/etc/nginx/nginx.conf
- owner: root
- group: wheel
- mode: "0644"
- register: homepage_nginx_conf
-
-- name: Check if nginx is enabled
- shell: service -j homepage nginx status
- changed_when: false
- failed_when: false
- register: homepage_nginx_enabled
-
-- name: Enable and start nginx
- shell: |
- service -j ingress nginx enable
- service -j ingress nginx restart
- when: homepage_nginx_enabled.rc != 0 or homepage_nginx_conf.changed
-
-- name: Set up crontab
- template:
- src: homepage/etc_crontab.j2
- dest: /usr/local/jails/containers/homepage/etc/crontab
- owner: root
- group: wheel
- mode: "0644"
- register: jail_homepage_etc_crontab
-
-- name: Restart cron
- service:
- name: cron
- state: restarted
- when: jail_homepage_etc_crontab.changed