Last active
August 29, 2015 14:13
-
-
Save jpadams/2533843a32f011ee115d to your computer and use it in GitHub Desktop.
fun with PuppetDB and exported resources
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| alias urlencode='python -c "import sys, urllib as ul; print ul.quote_plus(sys.argv[1])"' | |
| curl -X GET http://localhost:8080/v3/resources?query=`urlencode '["=", "type", "File"]'` | |
| # edit /etc/puppetlabs/puppet/environments/production/manifests/site.pp and add to node definition | |
| @@file { '/tmp/foo': | |
| ensure => file, | |
| content => "Hello, I'm an exported resource!\n", | |
| } | |
| curl -X GET http://localhost:8080/v3/resources?query=`urlencode '["=", "type", "File"]'` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment