[go: up one dir, main page]

Skip to content

Latest commit

 

History

History

bamboo-agents-puppet

Bamboo-agents-puppet

Installation of Bamboo Agents.

Updating Production/Staging machines

$ sudo -s
$ /etc/openmrs-puppet/bin/pull-changes.sh
$ /etc/openmrs-puppet/bin/run-puppet.sh

New Production/Staging machines

Requirements

  • Ubuntu 16.04
  • Puppet 6.x/Hiera/facter

Setting up new machine

  • SSH key for clone is configured via terraform
  • Files are initially copied from ansible

Development environment

Setting up

  • Virtualbox
  • Vagrant
  • git
  • ruby (>2.3.1 recommended. Use rvm or renv for easier installation)

Geppeto IDE is recommended, but not necessary.

Running locally

Install required gems

$ gem install bundler
$ bundle install

Download the correct versions of third party modules into 'modules' folder: $r10k puppetfile install -v When updating the Puppetfile, you'll need to rerun this command.

To run an Ubuntu 16.04 VM: $ vagrant up .... and go grab a coffee. Or two. Maybe a shower. While waiting for it to finish downloading the internet. Other vagrant commands can be found in Confluence

To run only the tests:

vagrant provision --provision-with serverspec

Using secrets

To encrypt data for vagrant:

eyaml encrypt --pkcs7-public-key=hieradata/keys/vagrant/public_key.pkcs7.pem -s "<your string>"

To encrypt data for production:

eyaml encrypt --pkcs7-public-key=hieradata/keys/production/public_key.pkcs7.pem -s "<your string>"

Tech considerations

While this runs in new puppet agents, it's a migration from a puppet 3 tree, so we are not using the default folders for puppet code.

It's not using puppet environments (it's not necessary in our case), we only use environments for hiera (puppet 3 style). So I decided to use a different puppet fact for that.

As we run masterless (and only on-demand), I decided to use a non-conventional folder.