mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-09-24 11:06:24 +02:00
Normalized OpenLDAP variables
This commit is contained in:
@@ -9,13 +9,13 @@
|
|||||||
src: "nginx.stream.conf.j2"
|
src: "nginx.stream.conf.j2"
|
||||||
dest: "{{ NGINX.DIRECTORIES.STREAMS }}{{ domains | get_domain(application_id) }}.conf"
|
dest: "{{ NGINX.DIRECTORIES.STREAMS }}{{ domains | get_domain(application_id) }}.conf"
|
||||||
notify: restart openresty
|
notify: restart openresty
|
||||||
when: applications | get_app_conf(application_id, 'network.public', True) | bool
|
when: OPENLDAP_NETWORK_SWITCH_PUBLIC | bool
|
||||||
|
|
||||||
- name: Remove {{ domains | get_domain(application_id) }}.conf if LDAP is not exposed to internet
|
- name: Remove {{ domains | get_domain(application_id) }}.conf if LDAP is not exposed to internet
|
||||||
file:
|
file:
|
||||||
path: "{{ NGINX.DIRECTORIES.STREAMS }}{{ domains | get_domain(application_id) }}.conf"
|
path: "{{ NGINX.DIRECTORIES.STREAMS }}{{ domains | get_domain(application_id) }}.conf"
|
||||||
state: absent
|
state: absent
|
||||||
when: not applications | get_app_conf(application_id, 'network.public', True) | bool
|
when: not OPENLDAP_NETWORK_SWITCH_PUBLIC | bool
|
||||||
|
|
||||||
- name: create docker network for LDAP, so that other applications can access it
|
- name: create docker network for LDAP, so that other applications can access it
|
||||||
community.docker.docker_network:
|
community.docker.docker_network:
|
||||||
@@ -37,7 +37,7 @@
|
|||||||
- name: "Reset LDAP Credentials"
|
- name: "Reset LDAP Credentials"
|
||||||
include_tasks: 01_credentials.yml
|
include_tasks: 01_credentials.yml
|
||||||
when:
|
when:
|
||||||
- applications | get_app_conf(application_id, 'network.local')
|
- OPENLDAP_NETWORK_SWITCH_LOCAL | bool
|
||||||
- applications | get_app_conf(application_id, 'provisioning.credentials', True)
|
- applications | get_app_conf(application_id, 'provisioning.credentials', True)
|
||||||
|
|
||||||
- name: "create directory {{OPENLDAP_LDIF_PATH_HOST}}{{item}}"
|
- name: "create directory {{OPENLDAP_LDIF_PATH_HOST}}{{item}}"
|
||||||
|
@@ -23,4 +23,6 @@ OPENLDAP_VOLUME: "{{ applications | get_app_conf(application_id,
|
|||||||
OPENLDAP_NETWORK: "{{ applications | get_app_conf(application_id, 'docker.network') }}"
|
OPENLDAP_NETWORK: "{{ applications | get_app_conf(application_id, 'docker.network') }}"
|
||||||
|
|
||||||
# Network
|
# Network
|
||||||
OPENLDAP_NETWORK_EXPOSE_LOCAL: "{{ applications | get_app_conf(application_id, 'network.public') | bool or applications | get_app_conf(application_id, 'network.local') | bool }}"
|
OPENLDAP_NETWORK_SWITCH_PUBLIC: "{{ applications | get_app_conf(application_id, 'network.public') }}"
|
||||||
|
OPENLDAP_NETWORK_SWITCH_LOCAL: "{{ applications | get_app_conf(application_id, 'network.local') }}"
|
||||||
|
OPENLDAP_NETWORK_EXPOSE_LOCAL: "{{ OPENLDAP_NETWORK_SWITCH_PUBLIC | bool or OPENLDAP_NETWORK_SWITCH_LOCAL | bool }}"
|
Reference in New Issue
Block a user