Skip to content

Instantly share code, notes, and snippets.

@jacobwyke
jacobwyke / puppetserver
Last active August 10, 2016 22:51
Puppetserver Monit config file
#
# /etc/monit/conf.d/puppetserver
# Monit file for puppetserver
#
check process puppetserver with pidfile /var/run/puppetlabs/puppetserver/puppetserver.pid
start program "/usr/bin/service puppetserver start" with timeout 120 seconds
stop program "/usr/bin/service puppetserver stop" with timeout 120 seconds
if failed port 8140 with timeout 30 seconds and retry 3 times 3 times within 3 cycles then restart
if 5 restarts within 5 cycles then timeout
@piscisaureus
piscisaureus / pr.md
Created August 13, 2012 16:12
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this: