con esto ya logra sacar el dominio wildcard,

estoy ahora peleando con bugs en el proxy
This commit is contained in:
Bet@ 2024-09-11 18:21:01 -03:00
parent 52e7da204d
commit 4bb2c14c83
4 changed files with 15 additions and 7 deletions

View File

@ -44,7 +44,7 @@
set_fact:
matrix_loop: "{{ matrix_loop | default([]) | union([ domino ]) }}"
with_items: "{{ matrix }}"
when: "{{ domino.domains is defined }}"
when: "{{ domino.domains is defined and domino.nodo is defined }}"
loop_control:
loop_var: domino

View File

@ -1,18 +1,25 @@
- set_fact:
custom_vhost: "roles/{{ vhost.roles[0] }}/templates/vhost.conf"
vhost_dest: "{{ vhosts_path }}/{{ vhost.domains[0] }}.conf"
proxy_conf: "roles/{{ vhost.roles[0] }}/templates/proxy.conf"
- block:
- set_fact:
custom_vhost: "roles/{{ vhost.roles[0] }}/templates/vhost.conf"
- set_fact:
proxy_conf: "roles/{{ vhost.roles[0] }}/templates/proxy.conf"
when: vhost.roles is defined
- set_fact:
proxy_conf_look: "{{ lookup('template', proxy_conf) }}"
when: proxy_conf is is_file
when: proxy_conf is defined and proxy_conf is is_file
- debug:
msg: "{{ vhost }}"
- name: generate default vhosts
template:
src: "{{ default_vhost }}"
dest: "{{ vhost_dest }}"
when: custom_vhost is not is_file
when: custom_vhost is undefined or custom_vhost is not is_file
notify:
- reload proxy
@ -20,6 +27,6 @@
template:
src: "{{ custom_vhost }}"
dest: "{{ vhost_dest }}"
when: custom_vhost is is_file
when: custom_vhost is defined and custom_vhost is is_file
notify:
- reload proxy

View File

@ -12,6 +12,7 @@
rsync_opts:
- "--exclude=.git"
tags: rap
creates: "{{ rap_path }}"
- name: agregar nodos a la VPN
shell: