From 69f8caf7939149ffea3d3c59e0cfdf7fa6134860 Mon Sep 17 00:00:00 2001
From: ludovicp <ludovicp@localhost>
Date: Wed, 03 Dec 2008 20:24:43 +0000
Subject: [PATCH] Add editing, copying and import of opends SMF manifest.
---
opends/resource/configure | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
diff --git a/opends/resource/configure b/opends/resource/configure
index c70b134..4b17c2e 100755
--- a/opends/resource/configure
+++ b/opends/resource/configure
@@ -62,5 +62,20 @@
# Version info was on requested
exit 0
else
+ if test ${RETURN_CODE} -eq 0
+ then
+ # Now update SMF manifest, cp it to the right place and import it
+ USER_GROUP=`ls -ld ${INSTANCE_ROOT} | cut -c16-33`
+ USERNAME=`echo ${USER_GROUP} | cut -c1-8`
+ GROUPNAME=`echo ${USER_GROUP} | cut -c9-16`
+ if test "${USERNAME}" = "ldap" -a "$GROUPNAME" = "ldap"
+ then
+ cp ${INSTALL_ROOT}/resources/opends-manifest.xml /var/svc/manifest/network/ldap/
+ else
+ cat ${INSTALL_ROOT}/resources/opends-manifest.xml | sed -e "s/user='ldap/user='${USERNAME}/;s/group='ldap/group='${GROUPNAME}/" > /tmp/opends-manifest.$$
+ cp /tmp/opends-manifest.$$ /var/svc/manifest/network/ldap/opends-manifest.xml
+ fi
+ /usr/sbin/svccfg import /var/svc/manifest/network/ldap/opends-manifest.xml
+ fi
exit ${RETURN_CODE}
fi
--
Gitblit v1.10.0