Skip to content

Instantly share code, notes, and snippets.

@workmad3
Created April 8, 2014 20:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save workmad3/10182427 to your computer and use it in GitHub Desktop.
Save workmad3/10182427 to your computer and use it in GitHub Desktop.
config.json goes in <chef-repo>/.berkshelf/api-server
berkshelf-api.sh script goes in <chef-repo>
If you use bundler in your chef-repo, add berkshelf-api to the Gemfile, otherwise 'gem install berkshelf-api'
#!/bin/bash
set -e
pushd "$(dirname $0)"
berks-api -p ${1-8000} -c .berkshelf/api-server/config.json -q
popd
exit 0
{
"endpoints": [
{
"type": "chef_server",
"options": {
"url": "<your chef server>",
"client_name": "<your workstation client name>",
"client_key": "<path to your workstation client key>"
}
},
{
"type": "opscode",
"options": {
"url": "http://cookbooks.opscode.com/api/v1"
}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment