Add server.ip in whitelist
This commit is contained in:
parent
afe60bbf47
commit
6e78f02cd4
3 changed files with 13 additions and 1 deletions
|
@ -14,6 +14,9 @@ server:
|
||||||
port: 22
|
port: 22
|
||||||
peers: test
|
peers: test
|
||||||
|
|
||||||
|
private_network:
|
||||||
|
extra_ips_whitelist: []
|
||||||
|
|
||||||
acme:
|
acme:
|
||||||
email: test@test.fr
|
email: test@test.fr
|
||||||
debug: true
|
debug: true
|
||||||
|
|
|
@ -12,9 +12,14 @@
|
||||||
loop:
|
loop:
|
||||||
- { src: 'docker-compose.yml', dest: 'docker-compose.yml' }
|
- { src: 'docker-compose.yml', dest: 'docker-compose.yml' }
|
||||||
- { src: 'config/traefik.yml', dest: 'config/traefik.yml' }
|
- { src: 'config/traefik.yml', dest: 'config/traefik.yml' }
|
||||||
- { src: 'config/dynamic_conf.yml', dest: 'config/dynamic_conf.yml' }
|
|
||||||
register: traefik_copy_templates_results
|
register: traefik_copy_templates_results
|
||||||
|
|
||||||
|
# Avoid restart docker if dynamic_conf updated
|
||||||
|
- name: Copy dynamic_conf conf
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "config/dynamic_conf.yml"
|
||||||
|
dest: "traefik/config/dynamic_conf.yml"
|
||||||
|
|
||||||
- name: Update and restart container
|
- name: Update and restart container
|
||||||
community.docker.docker_compose:
|
community.docker.docker_compose:
|
||||||
project_src: traefik
|
project_src: traefik
|
||||||
|
|
|
@ -4,6 +4,10 @@ http:
|
||||||
ipWhiteList:
|
ipWhiteList:
|
||||||
sourceRange:
|
sourceRange:
|
||||||
- "{{ server.vpn.subnet }}"
|
- "{{ server.vpn.subnet }}"
|
||||||
|
- "{{ server.ip }}"
|
||||||
|
{% for ip in private_network.extra_ips_whitelist %}
|
||||||
|
- "{{ ip }}"
|
||||||
|
{% endfor %}
|
||||||
routers:
|
routers:
|
||||||
octoPrint-secure:
|
octoPrint-secure:
|
||||||
entryPoints:
|
entryPoints:
|
||||||
|
|
Loading…
Reference in a new issue