Automatic provisioning using Chef, Puppet, etc.

Installing test-kitchen from github

Normally you would do this to install test-kitchen: sudo gem install test-kitchen To get the latest stable dev version from github, do it rather this way: cd /tmp git clone cd test-kitchen/ sudo gem build test-kitchen.gemspec sudo gem install You eventuelly need to replace with the version that is shown after the […]

Install Jenkins on Debian

First of all add the key of the Jenkins server to apt: wget -q -O – | apt-key add – Then create the sources.list entry or better create a file in /etc/apt/sources.list.d/: echo "deb binary/" > /etc/apt/sources.list.d/jenkins.list Then install the package: apt-get update apt-get install jenkins Jenkins will by default run on port […]

Creating an encrypted Databag in Chef

Create a random encryption key: openssl rand -base64 512 | tr -d ‘\r\n’ > secret_key Use this to encrypt a data bag item named “passwords” located in a data bag named “production”: knife data bag create −−editor /usr/bin/vi −−secret-file ./secret_key production passwords This will open an text editor, example JSON data would be: { “id”: “passwords”, […]