Skip to content

Commit

Permalink
Merge pull request #52 from McAndersDK/ldif-remote
Browse files Browse the repository at this point in the history
Add support for ldif remote files
  • Loading branch information
lvps authored May 1, 2024
2 parents 4f815ff + a097790 commit 469ac30
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,12 @@ Default: `[]` · Can be changed: **No**

Install these additional LDIF files, by default none (empty array). This corresponds to the `InstallLdifFile` directive in the inf installation file for 389DS <= 1.3. From 1.4 onward, this is done via dsconf.

#### dirsrv_ldif_files_remote
Default: `false` - can be changed: Yes

The ldif file are on the remote server, not on the ansible controller.


#### dirsrv_install_additional_ldif_dir
Default: `/var/lib/dirsrv/slapd-{{ dirsrv_serverid }}/ldif` · Can be changed: **No**

Expand Down
3 changes: 2 additions & 1 deletion defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ dirsrv_install_examples: false
dirsrv_install_additional_ldif: []
# Cannot use /tmp, see https://github.com/lvps/389ds-server/issues/18
dirsrv_install_additional_ldif_dir: "/var/lib/dirsrv/slapd-{{ dirsrv_serverid }}/ldif"
# ldif files are already on remote server
dirsrv_ldif_files_remote: false

# Logging

dirsrv_logging:
audit:
enabled: false
Expand Down
2 changes: 2 additions & 0 deletions tasks/install_389ds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
copy:
src: "{{ item }}"
dest: "{% if dirsrv_legacy %}/tmp/{% else %}{{ dirsrv_install_additional_ldif_dir }}/{% endif %}{{ item | basename }}"
remote_src: "{{ dirsrv_ldif_files_remote }}"
mode: '400'
owner: dirsrv
group: dirsrv
Expand Down Expand Up @@ -98,6 +99,7 @@
copy:
src: "{{ item }}"
dest: "{{ dirsrv_install_additional_ldif_dir }}/{{ item | basename }}"
remote_src: "{{ dirsrv_ldif_files_remote }}"
mode: '400'
owner: dirsrv
group: dirsrv
Expand Down

0 comments on commit 469ac30

Please sign in to comment.