On Wed, Mar 17, 2010 at 07:10:20PM -0400, Derek Yarnell wrote:
> Hi,
> 
> Anyone running puppetd --test in their preseed late_command?  I
> can't seem to get it working as the installer hangs forever in the
> late_preseed stage.
> 
> This is what I am using,
> 
> d-i preseed/late_command string chroot /target; mount /proc;
> /usr/sbin/puppetd --test --server puppetserver.my.domain

What we did as a late command was the following:

d-i preseed/late_command in-target wget -O /target/etc/default/puppet 
http://DEPLOYMENT_SERVER/d-i/lenny/puppet.default

Which gets the following default file:

==== Begin /etc/default/puppet ====
# Defaults for puppet - sourced by /etc/init.d/puppet

# Start puppet on boot? 
START=yes

cat <<HERE > /etc/puppet/puppet.conf
[main]
logdir=/var/log/puppet
vardir=/var/lib/puppet
ssldir=/var/lib/puppet/ssl
rundir=/var/run/puppet
factpath=\$vardir/lib/facter
pluginsync=true
server=PUPPETMASTER
evaltrace=true
HERE

for n in `seq 1 30`; do
  ping -c 1 PUPPETMASTER >& /dev/null && break
  echo -n " $n"
  sleep 1
done

# Startup options
DAEMON_OPTS="-w 120"
==== End /etc/default/puppet ====

Then, when the machine boots for the first time, it has enough information to
contact the puppetmaster and do a run.  Since puppetd does a run when it
starts, this starts the configuration process.

Cheers,

-- 
Eric Gerlach, Network Administrator
Federation of Students
University of Waterloo
p: (519) 888-4567 x36329
e: [email protected]
w: http://feds.ca/

"To Serve, Empower, and Represent the Undergraduate Students of the University
of Waterloo"

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to