summaryrefslogtreecommitdiff
path: root/roles/sublab_web/handlers
diff options
context:
space:
mode:
Diffstat (limited to 'roles/sublab_web/handlers')
-rw-r--r--roles/sublab_web/handlers/as_webuser.yaml5
-rw-r--r--roles/sublab_web/handlers/main.yaml5
2 files changed, 10 insertions, 0 deletions
diff --git a/roles/sublab_web/handlers/as_webuser.yaml b/roles/sublab_web/handlers/as_webuser.yaml
new file mode 100644
index 0000000..53c6444
--- /dev/null
+++ b/roles/sublab_web/handlers/as_webuser.yaml
@@ -0,0 +1,5 @@
+---
+- name: Rebuild subweb website
+ shell: python template.py
+ args:
+ chdir: "/var/www/{{sublab_web_server_name}}/htdocs/scripts"
diff --git a/roles/sublab_web/handlers/main.yaml b/roles/sublab_web/handlers/main.yaml
new file mode 100644
index 0000000..1ea02c8
--- /dev/null
+++ b/roles/sublab_web/handlers/main.yaml
@@ -0,0 +1,5 @@
+---
+- include: as_webuser.yaml
+ become: yes
+ become_method: su
+ become_user: sublab_web