1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-02 01:20:54 +00:00

- Install rc.d scripts [1]

- Install default config file [1]
- Add PORTDOCS in pkg-plist [2]

PR:		110618 [1], 110543 [2]
Submitted by:	Tomoyuki Sakurai <cherry AT trombik.org> (maintainer) [1]
		Robert Gogolok <gogo AT cs.uni-sb.de> [2]
Approved by:	clsung (mentor)
This commit is contained in:
Li-Wen Hsu 2007-04-13 13:37:08 +00:00
parent 985042c3ae
commit 062c564b9f
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=189902
8 changed files with 226 additions and 84 deletions

View File

@ -7,6 +7,7 @@
PORTNAME= puppet
PORTVERSION= 0.22.1
PORTREVISION= 1
CATEGORIES= sysutils
MASTER_SITES= http://www.reductivelabs.com/downloads/puppet/
EXTRACT_SUFX= .tgz
@ -19,6 +20,7 @@ RUN_DEPENDS= ${BUILD_DEPENDS}
NO_BUILD= yes
USE_RUBY= yes
USE_RC_SUBR= puppetmasterd puppetd
DOCS= CHANGELOG TODO README LICENSE COPYING
@ -35,7 +37,18 @@ do-install:
.endfor
${INSTALL} -d ${EXAMPLESDIR}
${CP} -R ${WRKSRC}/examples/* ${EXAMPLESDIR}
@${CHOWN} -R root:wheel ${EXAMPLESDIR}
@${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${EXAMPLESDIR}
.endif
post-install:
${INSTALL} -d ${PREFIX}/etc/${PORTNAME}
.for DIR in ssl manifests
${INSTALL} -d ${PREFIX}/etc/${PORTNAME}/${DIR}
.endfor
${RUBY} ${PREFIX}/bin/puppetmasterd \
--confdir=${PREFIX}/etc/${PORTNAME} \
--genconfig | \
${SED} -e 's/genconfig = true/# genconfig = false/' \
> ${PREFIX}/etc/${PORTNAME}/${PORTNAME}.conf-dist
.include <bsd.port.post.mk>

View File

@ -0,0 +1,27 @@
#!/bin/sh
#
# PROVIDE: puppetd
# REQUIRE: NETWORK
# Add the following lines to /etc/rc.conf to enable puppetd:
#
# puppetmasterd_enable="YES"
. %%RC_SUBR%%
name="puppetd"
rcvar=`set_rcvar`
command="%%PREFIX%%/bin/${name}"
command_interpreter="${prefix}/bin/ruby18"
load_rc_config "$name"
: ${puppetd_enable="NO"}
: ${puppetd_confdir="%%PREFIX%%/etc/puppet"}
: ${puppetd_pid="/var/run/puppet/${name}.pid"}
: ${puppetd_flags="--confdir $puppetd_confdir "}
command_args="$puppetd_flags"
pidfile="$puppetd_pid"
run_rc_command "$1"

View File

@ -0,0 +1,27 @@
:#!/bin/sh
#
# PROVIDE: puppetmasterd
# REQUIRE: NETWORK
# Add the following lines to /etc/rc.conf to enable puppetmasterd:
#
# puppetmasterd_enable="YES"
. %%RC_SUBR%%
name="puppetmasterd"
rcvar=`set_rcvar`
command="%%PREFIX%%/bin/${name}"
command_interpreter="${prefix}/bin/ruby18"
load_rc_config "$name"
: ${puppetmasterd_enable="NO"}
: ${puppetmasterd_confdir="%%PREFIX%%/etc/puppet"}
: ${puppetmasterd_pid="/var/run/puppet/${name}.pid"}
: ${puppetmasterd_flags="--confdir $puppetmasterd_confdir "}
command_args="$puppetmasterd_flags"
pidfile="$puppetmasterd_pid"
run_rc_command "$1"

View File

@ -275,45 +275,49 @@ bin/puppetmasterd
@dirrmtry %%RUBY_SITELIBDIR%%/puppet/external
@dirrmtry %%RUBY_SITELIBDIR%%/puppet/client
@dirrmtry %%RUBY_SITELIBDIR%%/puppet
%%DOCSDIR%%/CHANGELOG
%%DOCSDIR%%/TODO
%%DOCSDIR%%/README
%%DOCSDIR%%/LICENSE
%%DOCSDIR%%/COPYING
%%PORTDOCS%%%%DOCSDIR%%/CHANGELOG
%%PORTDOCS%%%%DOCSDIR%%/TODO
%%PORTDOCS%%%%DOCSDIR%%/README
%%PORTDOCS%%%%DOCSDIR%%/LICENSE
%%PORTDOCS%%%%DOCSDIR%%/COPYING
%%PORTDOCS%%@dirrm %%DOCSDIR%%
%%EXAMPLESDIR%%/root/bin/sleeper
%%EXAMPLESDIR%%/root/etc/init.d/sleeper
%%EXAMPLESDIR%%/root/etc/puppet/puppetd.conf
%%EXAMPLESDIR%%/root/etc/puppet/fileserver.conf
%%EXAMPLESDIR%%/root/etc/puppet/puppetmasterd.conf
%%EXAMPLESDIR%%/root/etc/puppet/namespaceauth.conf
%%EXAMPLESDIR%%/root/etc/puppet/tagmail.conf
%%EXAMPLESDIR%%/root/etc/otherfile
%%EXAMPLESDIR%%/root/etc/configfile
%%EXAMPLESDIR%%/root/etc/debian-passwd
%%EXAMPLESDIR%%/root/etc/debian-syslog.conf
%%EXAMPLESDIR%%/code/allatonce
%%EXAMPLESDIR%%/code/head
%%EXAMPLESDIR%%/code/selectors
%%EXAMPLESDIR%%/code/execs
%%EXAMPLESDIR%%/code/nodes
%%EXAMPLESDIR%%/code/filerecursion
%%EXAMPLESDIR%%/code/components
%%EXAMPLESDIR%%/code/file.bl
%%EXAMPLESDIR%%/code/groups
%%EXAMPLESDIR%%/code/functions
%%EXAMPLESDIR%%/code/fileparsing
%%EXAMPLESDIR%%/code/svncommit
%%EXAMPLESDIR%%/code/filedefaults
%%EXAMPLESDIR%%/code/simpletests
%%EXAMPLESDIR%%/code/assignments
%%EXAMPLESDIR%%/code/relationships
%%EXAMPLESDIR%%/code/importing
%%EXAMPLESDIR%%/code/one
@dirrmtry %%EXAMPLESDIR%%/root/bin
@dirrmtry %%EXAMPLESDIR%%/root/etc/init.d
@dirrmtry %%EXAMPLESDIR%%/root/etc/puppet
@dirrmtry %%EXAMPLESDIR%%/root/etc
@dirrmtry %%EXAMPLESDIR%%/root
@dirrmtry %%EXAMPLESDIR%%/code
@dirrmtry %%EXAMPLESDIR%%
%%PORTDOCS%%%%EXAMPLESDIR%%/root/bin/sleeper
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/init.d/sleeper
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/puppetd.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/fileserver.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/puppetmasterd.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/namespaceauth.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/tagmail.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/otherfile
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/configfile
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/debian-passwd
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/debian-syslog.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/code/allatonce
%%PORTDOCS%%%%EXAMPLESDIR%%/code/head
%%PORTDOCS%%%%EXAMPLESDIR%%/code/selectors
%%PORTDOCS%%%%EXAMPLESDIR%%/code/execs
%%PORTDOCS%%%%EXAMPLESDIR%%/code/nodes
%%PORTDOCS%%%%EXAMPLESDIR%%/code/filerecursion
%%PORTDOCS%%%%EXAMPLESDIR%%/code/components
%%PORTDOCS%%%%EXAMPLESDIR%%/code/file.bl
%%PORTDOCS%%%%EXAMPLESDIR%%/code/groups
%%PORTDOCS%%%%EXAMPLESDIR%%/code/functions
%%PORTDOCS%%%%EXAMPLESDIR%%/code/fileparsing
%%PORTDOCS%%%%EXAMPLESDIR%%/code/svncommit
%%PORTDOCS%%%%EXAMPLESDIR%%/code/filedefaults
%%PORTDOCS%%%%EXAMPLESDIR%%/code/simpletests
%%PORTDOCS%%%%EXAMPLESDIR%%/code/assignments
%%PORTDOCS%%%%EXAMPLESDIR%%/code/relationships
%%PORTDOCS%%%%EXAMPLESDIR%%/code/importing
%%PORTDOCS%%%%EXAMPLESDIR%%/code/one
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root/bin
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root/etc/init.d
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root/etc/puppet
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root/etc
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/code
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%
etc/puppet/puppet.conf-dist
@dirrmtry etc/puppet/ssl
@dirrmtry etc/puppet/manifests
@dirrmtry etc/puppet

View File

@ -7,6 +7,7 @@
PORTNAME= puppet
PORTVERSION= 0.22.1
PORTREVISION= 1
CATEGORIES= sysutils
MASTER_SITES= http://www.reductivelabs.com/downloads/puppet/
EXTRACT_SUFX= .tgz
@ -19,6 +20,7 @@ RUN_DEPENDS= ${BUILD_DEPENDS}
NO_BUILD= yes
USE_RUBY= yes
USE_RC_SUBR= puppetmasterd puppetd
DOCS= CHANGELOG TODO README LICENSE COPYING
@ -35,7 +37,18 @@ do-install:
.endfor
${INSTALL} -d ${EXAMPLESDIR}
${CP} -R ${WRKSRC}/examples/* ${EXAMPLESDIR}
@${CHOWN} -R root:wheel ${EXAMPLESDIR}
@${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${EXAMPLESDIR}
.endif
post-install:
${INSTALL} -d ${PREFIX}/etc/${PORTNAME}
.for DIR in ssl manifests
${INSTALL} -d ${PREFIX}/etc/${PORTNAME}/${DIR}
.endfor
${RUBY} ${PREFIX}/bin/puppetmasterd \
--confdir=${PREFIX}/etc/${PORTNAME} \
--genconfig | \
${SED} -e 's/genconfig = true/# genconfig = false/' \
> ${PREFIX}/etc/${PORTNAME}/${PORTNAME}.conf-dist
.include <bsd.port.post.mk>

View File

@ -0,0 +1,27 @@
#!/bin/sh
#
# PROVIDE: puppetd
# REQUIRE: NETWORK
# Add the following lines to /etc/rc.conf to enable puppetd:
#
# puppetmasterd_enable="YES"
. %%RC_SUBR%%
name="puppetd"
rcvar=`set_rcvar`
command="%%PREFIX%%/bin/${name}"
command_interpreter="${prefix}/bin/ruby18"
load_rc_config "$name"
: ${puppetd_enable="NO"}
: ${puppetd_confdir="%%PREFIX%%/etc/puppet"}
: ${puppetd_pid="/var/run/puppet/${name}.pid"}
: ${puppetd_flags="--confdir $puppetd_confdir "}
command_args="$puppetd_flags"
pidfile="$puppetd_pid"
run_rc_command "$1"

View File

@ -0,0 +1,27 @@
:#!/bin/sh
#
# PROVIDE: puppetmasterd
# REQUIRE: NETWORK
# Add the following lines to /etc/rc.conf to enable puppetmasterd:
#
# puppetmasterd_enable="YES"
. %%RC_SUBR%%
name="puppetmasterd"
rcvar=`set_rcvar`
command="%%PREFIX%%/bin/${name}"
command_interpreter="${prefix}/bin/ruby18"
load_rc_config "$name"
: ${puppetmasterd_enable="NO"}
: ${puppetmasterd_confdir="%%PREFIX%%/etc/puppet"}
: ${puppetmasterd_pid="/var/run/puppet/${name}.pid"}
: ${puppetmasterd_flags="--confdir $puppetmasterd_confdir "}
command_args="$puppetmasterd_flags"
pidfile="$puppetmasterd_pid"
run_rc_command "$1"

View File

@ -275,45 +275,49 @@ bin/puppetmasterd
@dirrmtry %%RUBY_SITELIBDIR%%/puppet/external
@dirrmtry %%RUBY_SITELIBDIR%%/puppet/client
@dirrmtry %%RUBY_SITELIBDIR%%/puppet
%%DOCSDIR%%/CHANGELOG
%%DOCSDIR%%/TODO
%%DOCSDIR%%/README
%%DOCSDIR%%/LICENSE
%%DOCSDIR%%/COPYING
%%PORTDOCS%%%%DOCSDIR%%/CHANGELOG
%%PORTDOCS%%%%DOCSDIR%%/TODO
%%PORTDOCS%%%%DOCSDIR%%/README
%%PORTDOCS%%%%DOCSDIR%%/LICENSE
%%PORTDOCS%%%%DOCSDIR%%/COPYING
%%PORTDOCS%%@dirrm %%DOCSDIR%%
%%EXAMPLESDIR%%/root/bin/sleeper
%%EXAMPLESDIR%%/root/etc/init.d/sleeper
%%EXAMPLESDIR%%/root/etc/puppet/puppetd.conf
%%EXAMPLESDIR%%/root/etc/puppet/fileserver.conf
%%EXAMPLESDIR%%/root/etc/puppet/puppetmasterd.conf
%%EXAMPLESDIR%%/root/etc/puppet/namespaceauth.conf
%%EXAMPLESDIR%%/root/etc/puppet/tagmail.conf
%%EXAMPLESDIR%%/root/etc/otherfile
%%EXAMPLESDIR%%/root/etc/configfile
%%EXAMPLESDIR%%/root/etc/debian-passwd
%%EXAMPLESDIR%%/root/etc/debian-syslog.conf
%%EXAMPLESDIR%%/code/allatonce
%%EXAMPLESDIR%%/code/head
%%EXAMPLESDIR%%/code/selectors
%%EXAMPLESDIR%%/code/execs
%%EXAMPLESDIR%%/code/nodes
%%EXAMPLESDIR%%/code/filerecursion
%%EXAMPLESDIR%%/code/components
%%EXAMPLESDIR%%/code/file.bl
%%EXAMPLESDIR%%/code/groups
%%EXAMPLESDIR%%/code/functions
%%EXAMPLESDIR%%/code/fileparsing
%%EXAMPLESDIR%%/code/svncommit
%%EXAMPLESDIR%%/code/filedefaults
%%EXAMPLESDIR%%/code/simpletests
%%EXAMPLESDIR%%/code/assignments
%%EXAMPLESDIR%%/code/relationships
%%EXAMPLESDIR%%/code/importing
%%EXAMPLESDIR%%/code/one
@dirrmtry %%EXAMPLESDIR%%/root/bin
@dirrmtry %%EXAMPLESDIR%%/root/etc/init.d
@dirrmtry %%EXAMPLESDIR%%/root/etc/puppet
@dirrmtry %%EXAMPLESDIR%%/root/etc
@dirrmtry %%EXAMPLESDIR%%/root
@dirrmtry %%EXAMPLESDIR%%/code
@dirrmtry %%EXAMPLESDIR%%
%%PORTDOCS%%%%EXAMPLESDIR%%/root/bin/sleeper
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/init.d/sleeper
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/puppetd.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/fileserver.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/puppetmasterd.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/namespaceauth.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/puppet/tagmail.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/otherfile
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/configfile
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/debian-passwd
%%PORTDOCS%%%%EXAMPLESDIR%%/root/etc/debian-syslog.conf
%%PORTDOCS%%%%EXAMPLESDIR%%/code/allatonce
%%PORTDOCS%%%%EXAMPLESDIR%%/code/head
%%PORTDOCS%%%%EXAMPLESDIR%%/code/selectors
%%PORTDOCS%%%%EXAMPLESDIR%%/code/execs
%%PORTDOCS%%%%EXAMPLESDIR%%/code/nodes
%%PORTDOCS%%%%EXAMPLESDIR%%/code/filerecursion
%%PORTDOCS%%%%EXAMPLESDIR%%/code/components
%%PORTDOCS%%%%EXAMPLESDIR%%/code/file.bl
%%PORTDOCS%%%%EXAMPLESDIR%%/code/groups
%%PORTDOCS%%%%EXAMPLESDIR%%/code/functions
%%PORTDOCS%%%%EXAMPLESDIR%%/code/fileparsing
%%PORTDOCS%%%%EXAMPLESDIR%%/code/svncommit
%%PORTDOCS%%%%EXAMPLESDIR%%/code/filedefaults
%%PORTDOCS%%%%EXAMPLESDIR%%/code/simpletests
%%PORTDOCS%%%%EXAMPLESDIR%%/code/assignments
%%PORTDOCS%%%%EXAMPLESDIR%%/code/relationships
%%PORTDOCS%%%%EXAMPLESDIR%%/code/importing
%%PORTDOCS%%%%EXAMPLESDIR%%/code/one
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root/bin
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root/etc/init.d
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root/etc/puppet
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root/etc
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/root
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%/code
%%PORTDOCS%%@dirrmtry %%EXAMPLESDIR%%
etc/puppet/puppet.conf-dist
@dirrmtry etc/puppet/ssl
@dirrmtry etc/puppet/manifests
@dirrmtry etc/puppet