Blame SOURCES/MigrationTools-27-simple.patch

e96fd1
Allow the calling user to pass in arguments to ldapadd/ldapmodify.
e96fd1
e96fd1
diff -up MigrationTools-47/migrate_all_netinfo_offline.sh.patch3 MigrationTools-47/migrate_all_netinfo_offline.sh
e96fd1
--- MigrationTools-47/migrate_all_netinfo_offline.sh.patch3	2008-08-29 09:09:19.000000000 +0200
e96fd1
+++ MigrationTools-47/migrate_all_netinfo_offline.sh	2008-08-29 09:09:19.000000000 +0200
e96fd1
@@ -69,7 +69,7 @@ nidump hosts $DOM > $ETC_HOSTS
e96fd1
 nidump networks $DOM > $ETC_NETWORKS
e96fd1
 nidump aliases $DOM > $ETC_ALIASES
e96fd1
 
e96fd1
-. ${INSTDIR}migrate_all_offline.sh
e96fd1
+. ${INSTDIR}migrate_all_offline.sh "$@"
e96fd1
 
e96fd1
 rm -f $ETC_PASSWD
e96fd1
 rm -f $ETC_GROUP
e96fd1
diff -up MigrationTools-47/migrate_all_netinfo_online.sh.patch3 MigrationTools-47/migrate_all_netinfo_online.sh
e96fd1
--- MigrationTools-47/migrate_all_netinfo_online.sh.patch3	2008-08-29 09:09:19.000000000 +0200
e96fd1
+++ MigrationTools-47/migrate_all_netinfo_online.sh	2008-08-29 09:09:19.000000000 +0200
e96fd1
@@ -69,7 +69,7 @@ nidump hosts $DOM > $ETC_HOSTS
e96fd1
 nidump networks $DOM > $ETC_NETWORKS
e96fd1
 nidump aliases $DOM > $ETC_ALIASES
e96fd1
 
e96fd1
-. ${INSTDIR}migrate_all_online.sh
e96fd1
+. ${INSTDIR}migrate_all_online.sh "$@"
e96fd1
 
e96fd1
 rm -f $ETC_PASSWD
e96fd1
 rm -f $ETC_GROUP
e96fd1
diff -up MigrationTools-47/migrate_all_nis_offline.sh.patch3 MigrationTools-47/migrate_all_nis_offline.sh
e96fd1
--- MigrationTools-47/migrate_all_nis_offline.sh.patch3	2008-08-29 09:09:19.000000000 +0200
e96fd1
+++ MigrationTools-47/migrate_all_nis_offline.sh	2008-08-29 09:09:19.000000000 +0200
e96fd1
@@ -71,7 +71,7 @@ ypcat $DOMFLAG hosts > $ETC_HOSTS
e96fd1
 ypcat $DOMFLAG networks > $ETC_NETWORKS
e96fd1
 #ypcat $DOMFLAG -k aliases > $ETC_ALIASES
e96fd1
 
e96fd1
-. ${INSTDIR}migrate_all_offline.sh
e96fd1
+. ${INSTDIR}migrate_all_offline.sh "$@"
e96fd1
 
e96fd1
 rm -f $ETC_PASSWD
e96fd1
 rm -f $ETC_GROUP
e96fd1
diff -up MigrationTools-47/migrate_all_nis_online.sh.patch3 MigrationTools-47/migrate_all_nis_online.sh
e96fd1
--- MigrationTools-47/migrate_all_nis_online.sh.patch3	2008-08-29 09:09:19.000000000 +0200
e96fd1
+++ MigrationTools-47/migrate_all_nis_online.sh	2008-08-29 09:09:19.000000000 +0200
e96fd1
@@ -71,7 +71,7 @@ ypcat $DOMFLAG hosts > $ETC_HOSTS
e96fd1
 ypcat $DOMFLAG networks > $ETC_NETWORKS
e96fd1
 #ypcat $DOMFLAG -k aliases > $ETC_ALIASES
e96fd1
 
e96fd1
-. ${INSTDIR}migrate_all_online.sh
e96fd1
+. ${INSTDIR}migrate_all_online.sh "$@"
e96fd1
 
e96fd1
 rm -f $ETC_PASSWD
e96fd1
 rm -f $ETC_GROUP
e96fd1
diff -up MigrationTools-47/migrate_all_nisplus_offline.sh.patch3 MigrationTools-47/migrate_all_nisplus_offline.sh
e96fd1
--- MigrationTools-47/migrate_all_nisplus_offline.sh.patch3	2008-08-29 09:09:19.000000000 +0200
e96fd1
+++ MigrationTools-47/migrate_all_nisplus_offline.sh	2008-08-29 09:09:19.000000000 +0200
e96fd1
@@ -73,7 +73,7 @@ nisaddent -d networks $DOM > $ETC_NETWOR
e96fd1
 nisaddent -d netgroup $DOM > $ETC_NETGROUP
e96fd1
 niscat mail_aliases.org_dir.$DOM > $ETC_ALIASES
e96fd1
 
e96fd1
-. ${INSTDIR}migrate_all_offline.sh
e96fd1
+. ${INSTDIR}migrate_all_offline.sh "$@"
e96fd1
 
e96fd1
 rm -f $ETC_PASSWD
e96fd1
 rm -f $ETC_GROUP
e96fd1
diff -up MigrationTools-47/migrate_all_nisplus_online.sh.patch3 MigrationTools-47/migrate_all_nisplus_online.sh
e96fd1
--- MigrationTools-47/migrate_all_nisplus_online.sh.patch3	2008-08-29 09:09:19.000000000 +0200
e96fd1
+++ MigrationTools-47/migrate_all_nisplus_online.sh	2008-08-29 09:09:19.000000000 +0200
e96fd1
@@ -73,7 +73,7 @@ nisaddent -d networks $DOM > $ETC_NETWOR
e96fd1
 nisaddent -d netgroup $DOM > $ETC_NETGROUP
e96fd1
 niscat mail_aliases.org_dir.$DOM > $ETC_ALIASES
e96fd1
 
e96fd1
-. ${INSTDIR}migrate_all_online.sh
e96fd1
+. ${INSTDIR}migrate_all_online.sh "$@"
e96fd1
 
e96fd1
 rm -f $ETC_PASSWD
e96fd1
 rm -f $ETC_GROUP
e96fd1
diff -up MigrationTools-47/migrate_all_offline.sh.patch3 MigrationTools-47/migrate_all_offline.sh
e96fd1
--- MigrationTools-47/migrate_all_offline.sh.patch3	2008-08-29 09:09:19.000000000 +0200
e96fd1
+++ MigrationTools-47/migrate_all_offline.sh	2008-08-29 09:09:19.000000000 +0200
e96fd1
@@ -137,9 +137,9 @@ echo "Migrating netgroups (by host)..."
e96fd1
 $PERL -I${INSTDIR} ${INSTDIR}migrate_netgroup_byhost.pl	$ETC_NETGROUP >> $DB
e96fd1
 echo "Preparing LDAP database..."
e96fd1
 if [ "X$SLAPADD" = "X" ]; then
e96fd1
-	$LDIF2LDBM -i $DB
e96fd1
+	$LDIF2LDBM -i $DB "$@"
e96fd1
 else
e96fd1
-	$SLAPADD -l $DB
e96fd1
+	$SLAPADD -l $DB "$@"
e96fd1
 fi
e96fd1
 EXITCODE=$?
e96fd1
 
e96fd1
diff -up MigrationTools-47/migrate_all_online.sh.patch3 MigrationTools-47/migrate_all_online.sh
e96fd1
--- MigrationTools-47/migrate_all_online.sh.patch3	2008-08-29 09:09:19.000000000 +0200
e96fd1
+++ MigrationTools-47/migrate_all_online.sh	2008-08-29 09:09:19.000000000 +0200
e96fd1
@@ -194,13 +194,11 @@ $PERL -I${INSTDIR} ${INSTDIR}migrate_net
e96fd1
 
e96fd1
 echo "Importing into LDAP..."
e96fd1
 
e96fd1
- if [ -x /usr/sbin/slapadd ]; then
e96fd1
-   $LDAPADD -x -h $LDAPHOST -D "$LDAP_BINDDN" -w "$LDAP_BINDCRED" -f $DB
e96fd1
- elif [ -x /usr/local/sbin/slapadd ]; then
e96fd1
-   $LDAPADD -x -h $LDAPHOST -D "$LDAP_BINDDN" -w "$LDAP_BINDCRED" -f $DB
e96fd1
- else
e96fd1
-   $LDAPADD -h $LDAPHOST -D "$LDAP_BINDDN" -w "$LDAP_BINDCRED" -f $DB
e96fd1
- fi
e96fd1
+if [ `basename $LDAPADD` = "slapadd" ]; then
e96fd1
+	$LDAPADD -h $LDAPHOST -D "$LDAP_BINDDN" -w "$LDAP_BINDCRED" "$@" -f $DB
e96fd1
+else
e96fd1
+	$LDAPADD -x -h $LDAPHOST -D "$LDAP_BINDDN" -w "$LDAP_BINDCRED" "$@" -f $DB
e96fd1
+fi
e96fd1
 
e96fd1
 if [ $? -ne 0 ]; then
e96fd1
 	echo "$LDAPADD: returned non-zero exit status: saving failed LDIF to $DB"