19 lines
408 B
Bash
Executable file
19 lines
408 B
Bash
Executable file
#!/bin/bash
|
|
|
|
DESC="Exportation de l'annuaire LDAP"
|
|
|
|
. /usr/share/eole/schedule/config.sh
|
|
|
|
LDAPSAVDIR=$SAVDIR
|
|
LDAPSAVFILE=$LDAPSAVDIR/sauv_ldap.ldif
|
|
|
|
rm -f $LDAPSAVFILE
|
|
mkdir -p $LDAPSAVDIR
|
|
|
|
CreoleService slapd stop -c annuaire
|
|
CreoleRun "slapcat -v -f /etc/ldap/slapd.conf -o ldif-wrap=no" annuaire > $LDAPSAVFILE
|
|
slapd_error=$?
|
|
CreoleService slapd start -c annuaire
|
|
[ $slapd_error -ne 0 ] && exit 1
|
|
|
|
exit 0
|