[re2o-replica-ldap] Move files to /var/lib/slapd
Signed-off-by: Yohann D'ANELLO <ynerant@crans.org>certbot_on_virtu
parent
741a13b402
commit
3e4aac76d6
|
@ -13,7 +13,7 @@
|
|||
|
||||
- name: Check if installation was done
|
||||
stat:
|
||||
path: /root/.delete_me_to_reset_ldap_configuration
|
||||
path: /var/lib/slapd/.delete_me_to_reset_ldap_configuration
|
||||
register: installation
|
||||
|
||||
- name: Stop slapd
|
||||
|
@ -45,7 +45,7 @@
|
|||
- name: Copy ldif files
|
||||
template:
|
||||
src: 'ldap/{{ item }}.ldif.j2'
|
||||
dest: '/tmp/{{ item }}.ldif'
|
||||
dest: '/var/lib/slapd/{{ item }}.ldif'
|
||||
owner: openldap
|
||||
group: openldap
|
||||
mode: 0600
|
||||
|
@ -57,12 +57,12 @@
|
|||
|
||||
- name: Initialize re2o-ldap schema
|
||||
when: not installation.stat.exists
|
||||
shell: slapadd -n 0 -l /tmp/schema.ldif -F /etc/ldap/slapd.d/
|
||||
shell: slapadd -n 0 -l /var/lib/slapd/schema.ldif -F /etc/ldap/slapd.d/
|
||||
become_user: openldap
|
||||
|
||||
- name: Initialize re2o-ldap database
|
||||
when: not installation.stat.exists
|
||||
shell: slapadd -n 1 -l /tmp/db.ldif
|
||||
shell: slapadd -n 1 -l /var/lib/slapd/db.ldif
|
||||
become_user: openldap
|
||||
|
||||
- name: Start slapd
|
||||
|
@ -73,7 +73,7 @@
|
|||
|
||||
- name: Enable data replication
|
||||
when: not installation.stat.exists
|
||||
shell: ldapadd -Q -Y EXTERNAL -H ldapi:/// -f /tmp/consumer_simple_sync.ldif
|
||||
shell: ldapadd -Q -Y EXTERNAL -H ldapi:/// -f /var/lib/slapd/consumer_simple_sync.ldif
|
||||
|
||||
- name: Copy TLS certificate
|
||||
template:
|
||||
|
@ -88,7 +88,7 @@
|
|||
|
||||
- name: Load TLS certificates
|
||||
when: not installation.stat.exists
|
||||
shell: ldapmodify -Y EXTERNAL -H ldapi:/// -f /tmp/certinfo.ldif
|
||||
shell: ldapmodify -Y EXTERNAL -H ldapi:/// -f /var/lib/slapd/certinfo.ldif
|
||||
|
||||
- name: Enable LDAPS
|
||||
lineinfile:
|
||||
|
@ -101,7 +101,7 @@
|
|||
- name: Touch installation marker
|
||||
when: not installation.stat.exists
|
||||
file:
|
||||
path: /root/.delete_me_to_reset_ldap_configuration
|
||||
path: /var/lib/slapd/.delete_me_to_reset_ldap_configuration
|
||||
state: touch
|
||||
owner: root
|
||||
group: root
|
||||
|
|
Loading…
Reference in New Issue