diff options
Diffstat (limited to 'roles/nextcloud/tasks/main.yml')
-rw-r--r-- | roles/nextcloud/tasks/main.yml | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/roles/nextcloud/tasks/main.yml b/roles/nextcloud/tasks/main.yml index 8453ce65..fe65d62b 100644 --- a/roles/nextcloud/tasks/main.yml +++ b/roles/nextcloud/tasks/main.yml @@ -79,6 +79,43 @@ state: directory +- name: create image config dir + loop: "{{ nextcloud_instances | list }}" + loop_control: + label: "{{ item }}" + file: + path: "{{ nextcloud_base_path }}/{{ item }}/config" + state: directory + +- name: create apache vhost config + loop: "{{ nextcloud_instances | list }}" + loop_control: + label: "{{ item }}" + copy: + content: | + <VirtualHost *:8080> + ServerAdmin webmaster@localhost + DocumentRoot /var/www/html + + # SetEnv HTTPS on + # SetEnvIfNoCase X-Forwarded-Proto https HTTPS=on + + ErrorLog ${APACHE_LOG_DIR}/error.log + CustomLog ${APACHE_LOG_DIR}/access.log combined + </VirtualHost> + dest: "{{ nextcloud_base_path }}/{{ item }}/config/apache-site.conf" + +- name: configure apache to run on port 8080 only + loop: "{{ nextcloud_instances | list }}" + loop_control: + label: "{{ item }}" + copy: + content: | + Listen 8080 + dest: "{{ nextcloud_base_path }}/{{ item }}/config/ports.conf" + + + - name: generate pod manifests loop: "{{ nextcloud_instances | dict2items }}" loop_control: |