feat: Swag with reverse proxy for most services
This commit is contained in:
@@ -13,6 +13,22 @@
|
||||
group: root
|
||||
mode: 0755
|
||||
|
||||
- name: Copy authelia configuration.yml
|
||||
template:
|
||||
src: "authelia-configuration.yml"
|
||||
dest: /data/authelia/config/configuration.yml
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0755
|
||||
|
||||
- name: Copy authelia users.yml
|
||||
template:
|
||||
src: "authelia-users.yml"
|
||||
dest: /data/authelia/config/users_database.yml
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0755
|
||||
|
||||
- name: Run docker-compose
|
||||
ansible.builtin.shell:
|
||||
args:
|
||||
@@ -21,29 +37,41 @@
|
||||
|
||||
- name: Wait for config folder to be created
|
||||
wait_for:
|
||||
path: "/data/config/dns-conf/"
|
||||
path: "/data/swag/config/dns-conf/"
|
||||
delay: 10
|
||||
timeout: 30
|
||||
state: present
|
||||
|
||||
- name: Copy cloudflare.ini
|
||||
- name: Copy swag cloudflare.ini
|
||||
template:
|
||||
src: "cloudflare.ini"
|
||||
dest: /data/config/dns-conf/cloudflare.ini
|
||||
dest: /data/swag/config/dns-conf/cloudflare.ini
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0755
|
||||
|
||||
- name: Copy proxy confs
|
||||
- name: Copy swag proxy confs
|
||||
copy:
|
||||
src: "{{ item }}"
|
||||
dest: /data/config/nginx/proxy-confs/
|
||||
dest: /data/swag/config/nginx/proxy-confs/
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0755
|
||||
with_fileglob:
|
||||
- "templates/*.conf"
|
||||
|
||||
- name: Uncomment authelia-server on domain root
|
||||
ansible.builtin.replace:
|
||||
path: /data/swag/config/nginx/site-confs/default.conf
|
||||
regexp: '^(\s+)#(include \/config\/nginx\/authelia-server\.conf\;)$'
|
||||
replace: '\1 \2'
|
||||
|
||||
- name: Uncomment authelia-location on domain root
|
||||
ansible.builtin.replace:
|
||||
path: /data/swag/config/nginx/site-confs/default.conf
|
||||
regexp: '^(\s+)#(include \/config\/nginx\/authelia-location\.conf\;)$'
|
||||
replace: '\1 \2'
|
||||
|
||||
- name: Stop swag
|
||||
ansible.builtin.shell:
|
||||
args:
|
||||
|
||||
Reference in New Issue
Block a user