Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- root@sfdpuppet01 ~
- # echo $PATH
- /usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/data/puppet/reductivelabs.git/puppet/bin:/data/puppet/reductivelabs.git/facter/bin
- root@sfdpuppet01
- # cat /etc/profile.d/puppet.sh
- PUPPET_PATH=/data/puppet/reductivelabs.git
- PATH=$PATH:$PUPPET_PATH/puppet/bin:$PUPPET_PATH/facter/bin
- RUBYLIB=$PUPPET_PATH/puppet/lib:$PUPPET_PATH/facter/lib
- export PATH RUBYLIB
- THE INIT SCRIPT:
- #!/bin/bash
- # puppetmaster This shell script enables the puppetmaster server.
- #
- # Author: Duane Griffin <d.griffin@psenterprise.com>
- # Martin Vuk <martin.vuk@fri.uni-lj.si> (SuSE support)
- #
- # chkconfig: - 65 45
- #
- # description: Server for the puppet system management tool.
- # processname: puppetmaster
- ### BEGIN INIT INFO
- # Provides: puppetmaster
- # Required-Start: $local_fs $network $syslog
- # Should-Start:
- # Required-Stop:
- # Default-Start: 3 4 5
- # Default-Stop: 0 1 2 6
- # Short-Description: puppetmaster
- # Description: Server for the puppet system management tool.
- ### END INIT INFO
- #source /data/puppet/profile
- #source /etc/profile.d/puppet.sh
- #export PATH=/usr/bin:/sbin:/bin:/usr/sbin
- #PUPPET_PATH=/data/puppet/reductivelabs.git
- #PATH=$PATH:$PUPPET_PATH/puppet/bin:$PUPPET_PATH/facter/bin
- #RUBYLIB=$PUPPET_PATH/puppet/lib:$PUPPET_PATH/facter/lib
- #export PATH RUBYLIB
- #export PUPPET_PATH=/data/puppet/reductivelabs.git/puppet
- #export PATH=${PATH}:$PUPPET_PATH/bin
- #export FACTER_PATH=/data/puppet/reductivelabs.git/facter
- #export PATH=${PATH}:$FACTER_PATH/bin
- #. /data/puppet/profile
- # Redhat functions
- . /etc/rc.d/init.d/functions
- RETVAL=0
- # Run multiple puppetmasters on these ports
- PUPPETMASTERPORTS="8150 8151 8152 8153 8154"
- # Locking and run stuff
- RUNDIR=/var/puppet/run
- LOCKDIR=/var/lock/subsys/
- start() {
- local daemonargs=' --check $base --pidfile $pidfile'
- for pmp in $PUPPETMASTERPORTS ; do
- local pmargs="--servertype mongrel --masterport $pmp --pidfile \$pidfile --daemonize"
- start_proc puppetmaster-$pmp $daemonargs puppetmasterd $pmargs
- done
- #httpdargs="-f /etc/puppet/httpd.conf"
- #start_proc puppet-httpd $daemonargs httpd $httpdargs
- }
- start_proc() {
- local base=$1
- local pidfile=$RUNDIR/$base.pid
- local lockfile=$LOCKDIR/$base
- shift
- echo -n $"Starting $base: "
- eval daemon $*
- RETVAL=$?
- [ $RETVAL = 0 ] && touch ${lockfile}
- echo
- return $RETVAL
- }
- stop() {
- #stop_proc puppet-httpd
- for pmp in $PUPPETMASTERPORTS ; do
- stop_proc puppetmaster-$pmp
- done
- }
- stop_proc() {
- local base=$1
- local pidfile=$RUNDIR/$base.pid
- local lockfile=$LOCKDIR/$base
- echo -n $"Stopping $base: "
- killproc -p $pidfile $base
- RETVAL=$?
- [ $RETVAL -eq 0 ] && rm -f "$lockfile"
- echo
- return $RETVAL
- }
- status_pm() {
- for pmp in $PUPPETMASTERPORTS ; do
- status_proc puppetmaster-$pmp
- done
- status_proc puppet-httpd
- }
- status_proc() {
- local base=$1
- local pidfile=$RUNDIR/$base.pid
- local lockfile=$LOCKDIR/$base
- status -p $pidfile $base
- }
- case "$1" in
- start)
- start
- ;;
- stop)
- stop
- ;;
- restart|reload|force-reload)
- stop
- start
- ;;
- status)
- status_pm
- ;;
- *)
- echo $"Usage: $0 {start|stop|status|restart|reload|force-reload}"
- exit 1
- esac
- exit $RETVAL
- BACKGROUND:
- I had this all working fine with puppet installed from rpms. I wanted to move away from this and have our repo, and the puppet source pulling from a git pull so that its easier to merge, and give back. Since pulling down the repo from reductivelabs, and adding the new paths, it seems that its not finding things anymore. Not really sure why?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement