Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
39 lines (26 sloc) 1.02 KB


A simple library to access the Puppet REST API with Fabric

Fabpup consists of a single py file that you "include" in your and gives you a simple way to set Fabric's env.hosts lists with a list of hosts from Puppet based on a dictionary of facts to match on.


import fabpup

# settings - see for available settings
fabpup['host'] = ''   # your puppetmaster host

# create a dict with facts to match on
myfacts = {'facts.operatingsystem':'CentOS',

# return a list of hosts for Fabric
env.hosts = get_hosts_by_facts(myfacts)



Yes, not much to it. It only has support for the "facts_search" feature of the Puppet REST API, but I have plans to add everything else. Please fork if you're interested in helping out.

Something went wrong with that request. Please try again.