-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathldif-git-backup.conf
75 lines (69 loc) · 2.16 KB
/
ldif-git-backup.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
# Default parameters
#
# If parameters are not specified in this config file or via cmd-line args, the
# hard-coded defaults from below will be used
#
# ldif_cmd =
# ldif_file =
# ldif_stdin = False
# backup_dir = /var/backups/ldap
# commit_msg = ldif-git-backup
# excl_attrs =
# ldif_attr =
# no_gc = False
# no_rm = False
# no_add = False
# no_commit = False
# single_ldif = False
# ldif_name = db
# ldif_wrap = False
# ldif_v1 = False
# ldif_mem = False
# no_out = False
# Default configuration section:
#
# The default configuration section must be named `DEFAULT`
# Any unspecified parameters in other configuration sections will inherit their
# value from this section
#
[DEFAULT]
# Default ldif-git-backup parameters
#
# The default ldif-git-backup parameters section must be named `ldif-git-backup`
# If `ldif-git-backup` is run without specifying any configuration section using
# options `-c` or `--config`, the parameters from this section are used as
# default values. If a parameter is not specified, it is inherited from section
# `DEFAULT` if it is specified there, otherwise the hard-coded defaults apply
#
[ldif-git-backup]
# Examples
#
# ldif-git-backup uses the `configparser` module with extended interpolation
# https://docs.python.org/3/library/configparser.html
# below are some examples to show how it can be used with arbitrary options
#
# Variable syntax (from current section/DEFAULT): ${option}
# Variable syntax (from foreign section): ${section:option}
# Example section with arbitrary option to be used in subsequent sections
#
[config_common]
root_dir: /var/backups/ldap/config
# Example section to backup the configuration using slapcat:
#
# Use with `ldif-git-backup.py -c config_slapcat`
#
[config_slapcat]
backup_dir = ${config_common:root_dir}/slapcat
ldif_cmd = /usr/sbin/slapcat -n 0 -o ldif-wrap=no
single_ldif = True
ldif_name = config
# Example section to backup the configuration using ldapsearch:
#
# Use with `ldif-git-backup.py -c config_ldapsearch`
#
[config_ldapsearch]
backup_dir = ${config_common:root_dir}/ldapsearch
ldif_cmd = /usr/bin/ldapsearch -QLLL -Y EXTERNAL -H ldapi:// -o ldif-wrap=no
-b cn=config * +
single_ldif = True
ldif_name = config