pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/sysutils/puppet Install manifest and SMF methods for p...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/a287658e40b8
branches:  trunk
changeset: 398436:a287658e40b8
user:      tonnerre <tonnerre%pkgsrc.org@localhost>
date:      Sun Aug 30 21:57:07 2009 +0000

description:
Install manifest and SMF methods for puppetd and puppetmasterd when on
Solaris. Bump PKGREVISION.

XXX: This should be formalized for all services.

diffstat:

 sysutils/puppet/Makefile |  28 ++++++++++++++++++++++++++--
 sysutils/puppet/PLIST    |   6 +++++-
 2 files changed, 31 insertions(+), 3 deletions(-)

diffs (87 lines):

diff -r 4503dbc58982 -r a287658e40b8 sysutils/puppet/Makefile
--- a/sysutils/puppet/Makefile  Sun Aug 30 17:18:22 2009 +0000
+++ b/sysutils/puppet/Makefile  Sun Aug 30 21:57:07 2009 +0000
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.4 2009/02/08 23:01:56 tonnerre Exp $
+# $NetBSD: Makefile,v 1.5 2009/08/30 21:57:07 tonnerre Exp $
 
 DISTNAME=              puppet-0.24.7
+PKGREVISION=           1
 CATEGORIES=            sysutils
 
 MAINTAINER=            tonnerre%NetBSD.org@localhost
@@ -8,6 +9,8 @@
 MASTER_SITE=           http://reductivelabs.com/downloads/gems/
 COMMENT=               Configuration management framework written in Ruby
 
+.include "../../mk/bsd.prefs.mk"
+
 DEPENDS+=              ${RUBY_PKGPREFIX}-facter>=1.3.8:../../sysutils/ruby-facter
 
 GEM_BUILD=             gemspec
@@ -26,10 +29,21 @@
 SUBST_FILES.prefix+=   conf/solaris/smf/puppetmasterd.xml
 SUBST_FILES.prefix+=   man/man8/puppetrun.8 man/man8/puppet.conf.8
 SUBST_SED.prefix=      -e "s|/etc/puppet|${PKG_SYSCONFDIR}|g"
+SUBST_SED.prefix+=     -e "s|/opt/csw/lib|${PREFIX}/lib|g"
 
 EGDIR=                 ${PREFIX}/share/examples/${PKGBASE}
 CONF_FILES=            ${EGDIR}/puppet.conf ${PKG_SYSCONFDIR}/puppet.conf
 
+PLIST_VARS+=           sunos
+
+.if ${OPSYS} == "SunOS"
+INSTALLATION_DIRS=     lib/svc/method ${EGDIR}/svc
+CONF_DIR+=             ${VARBASE}/svc/manifest
+CONF_FILES+=           ${EGDIR}/svc/puppetd.xml ${VARBASE}/svc/manifest/puppetd.xml
+CONF_FILES+=           ${EGDIR}/svc/puppetmasterd.xml ${VARBASE}/svc/manifest/puppetmasterd.xml
+PLIST.sunos=           yes
+.endif
+
 pre-build:
        cd ${WRKSRC} && ${RUBY} -Ilib bin/puppetmasterd                 \
                --confdir=${PKG_SYSCONFDIR:Q} --rundir=${VARBASE:Q}/run \
@@ -39,8 +53,18 @@
 
 post-install:
        ${INSTALL_DATA_DIR} ${DESTDIR}${EGDIR}
-       ${INSTALL_DATA} ${WRKSRC}/examples/puppet.conf          \
+       ${INSTALL_DATA} ${WRKSRC}/examples/puppet.conf                  \
                ${DESTDIR}${EGDIR}
+.if ${OPSYS} == "SunOS"
+       ${INSTALL_DATA} ${WRKSRC}/conf/solaris/smf/puppetd.xml          \
+               ${DESTDIR}${EGDIR}/svc
+       ${INSTALL_DATA} ${WRKSRC}/conf/solaris/smf/puppetmasterd.xml    \
+               ${DESTDIR}${EGDIR}/svc
+       ${INSTALL_SCRIPT} ${WRKSRC}/conf/solaris/smf/svc-puppetd        \
+               ${DESTDIR}${PREFIX}/lib/svc/method
+       ${INSTALL_SCRIPT} ${WRKSRC}/conf/solaris/smf/svc-puppetmasterd  \
+               ${DESTDIR}${PREFIX}/lib/svc/method
+.endif
 
 .include "../../misc/rubygems/rubygem.mk"
 .include "../../mk/bsd.pkg.mk"
diff -r 4503dbc58982 -r a287658e40b8 sysutils/puppet/PLIST
--- a/sysutils/puppet/PLIST     Sun Aug 30 17:18:22 2009 +0000
+++ b/sysutils/puppet/PLIST     Sun Aug 30 21:57:07 2009 +0000
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.5 2009/06/14 18:16:12 joerg Exp $
+@comment $NetBSD: PLIST,v 1.6 2009/08/30 21:57:07 tonnerre Exp $
 bin/puppet
 bin/puppetca
 bin/puppetd
@@ -6,6 +6,8 @@
 bin/puppetmasterd
 bin/puppetrun
 bin/ralsh
+${PLIST.sunos}lib/svc/method/svc-puppetd
+${PLIST.sunos}lib/svc/method/svc-puppetmasterd
 ${GEM_HOME}/cache/puppet-${PKGVERSION}.gem
 ${GEM_LIBDIR}/CHANGELOG
 ${GEM_LIBDIR}/COPYING
@@ -985,3 +987,5 @@
 share/examples/puppet/puppet.conf
 share/examples/rc.d/puppetd
 share/examples/rc.d/puppetmasterd
+${PLIST.sunos}share/examples/puppet/svc/puppetd.xml
+${PLIST.sunos}share/examples/puppet/svc/puppetmasterd.xml



Home | Main Index | Thread Index | Old Index