dev-ds01.pixelpark.com:
replica_id: 1
slapd_instance: dev-ds01
+ ldap_uri: 'ldaps://dev-ds01.pixelpark.com'
dev-ds02.pixelpark.com:
replica_id: 2
slapd_instance: dev-ds02
+ ldap_uri: 'ldaps://dev-ds02.pixelpark.com'
dev-ds03.pixelpark.com:
replica_id: 3
slapd_instance: dev-ds03
+ ldap_uri: 'ldaps://dev-ds03.pixelpark.com'
haproxy_servers:
hosts:
dev-ds-hap01.pixelpark.com: {}
replication_manager_password_file: '/root/.private/dirserv-repl-mngr-pwd.txt'
replication_manager_idle_timeout: 0
haproxy_backend_name: 'be-ldap-dev1'
+ ldaps_validate_certs: false
# ds389_plugin_attr_uniq_purge: false
ds389_plugin_attr_uniq_attributes:
'uid':
stage-ds01-spk.spk.pixelpark.net:
replica_id: 1
slapd_instance: stage-ds01-spk
+ ldap_uri: 'ldaps://stage-ds01-spk.spk.pixelpark.net'
stage-ds02-spk.spk.pixelpark.net:
replica_id: 2
slapd_instance: stage-ds02-spk
+ ldap_uri: 'ldaps://stage-ds02-spk.spk.pixelpark.net'
haproxy_servers:
hosts:
live-ldap-hap01.spk.pixelpark.net: {}
replication_manager_password_file: '/root/.private/dirserv-repl-mngr-pwd.txt'
replication_manager_idle_timeout: 0
haproxy_backend_name: 'be-stage-ldap'
+ ldaps_validate_certs: false
ds389_plugin_attr_uniq_config: false
# ds389_plugin_attr_uniq_purge: false
ds389_plugin_attr_uniq_attributes:
msg: "The Directory Server instances '{{ slapd_instance }}' was not found on '{{ inventory_hostname }}'."
when: slapd_instance not in instances_389ds
+- name: 'Get the admin password from the password file.'
+ ansible.builtin.shell: "cat {{ dirsrv_root_passwd_file | quote }}"
+ register: get_dirsrv_root_passwd
+ check_mode: false
+ changed_when: false
+ no_log: true
+
+- name: 'Get the admin password.'
+ ansible.builtin.set_fact:
+ dirsrv_root_passwd: "{{ get_dirsrv_root_passwd.stdout }}"
+ no_log: true
+
+- name: 'Got no admin password'
+ ansible.builtin.fail:
+ msg: "Did not found a password in file {{ dirsrv_root_passwd_file || quote }}."
+ when: dirsrv_root_passwd == ''
# vim: filetype=yaml