+ All Categories
Home > Software > Puppet Camp Denver 2015: Developing and Testing with Enhanced Oscar

Puppet Camp Denver 2015: Developing and Testing with Enhanced Oscar

Date post: 14-Jul-2015
Category:
Upload: puppet-labs
View: 371 times
Download: 1 times
Share this document with a friend
Popular Tags:
28
Developing and Testing with “Enhanced” Oscar Jeff Scelza [email protected] Twitter: @theFunkyPuma
Transcript

Developing and Testing with “Enhanced” Oscar

Jeff [email protected]: @theFunkyPuma

● Almost 20 years in IT

● Currently work at TWC doing DevOps work

● Lover of Technology and Knowledge

About me

● Checkout various modules locally● Make changes, commit, and push to repository● Git Hooks push to Jenkins● Jenkins automatically Kicks off a CI process and pushes

to our masters● Agents then pick up the changes

http://www.slideshare.net/philzimmerman900/killer-r10k

Our Normal Process

Not the best for starting new development or requiring major changes!

So, what to do while keeping inline with tools and process already being used.

Amazing process but...

Enter local system development

R10KRSpec-Puppet

VirtualBox is a general-purpose full virtualizer for x86 hardware, targeted at server, desktop and embedded use.

VirtualBox

● Is a set of Vagrant plugins and templates that build up a full Puppet Enterprise environment based on top of Vagrant create by Adrian Thebo

● What makes up Oscar?

○ auto_network: configure private network interfaces○ config_builder: Yaml based configuration for Vagrant○ hosts: Manages guest DNS resolution w/ auto_network○ pe_build: Manages rapid setup Puppet Enterprise

And Oscar?

● Generate a working environment from template

vagrant oscar init

● Initialize current working directory with a sub Vagrantfile that loads Oscar and generate generic configs

vagrant oscar init-vms

Oscar: commands

● What do the files look like?

● What cool thing can we do?

● How do can I code locally and use a master/slave configuration?

Oscar file Break out

Vagrantfile

box.yaml

roles.yaml

pe_buid.yaml

vm.yaml

● Customization of files/dirs:

Making Oscar “Enhanced”

puppet.conf.master

puppet.conf.agent

But what about the modules?

Setting up the Master and Agent(s)

Using rake to manage classes

Initial Puppet agent run

Using Rspec to valid the Catalog

Troubleshooting with DOT files

● ServerSpec

Serverspec tests your servers' actual state by executing command locally, via SSH, via WinRM, via Docker API and so on. So you don't need to install any agent softwares on your servers and can use any configuration management tools, Puppet, Chef, CFEngine, Itamae and so on.

● BeakerBeaker is an acceptance testing harness for Puppet PE and other Puppet Projects. It can also be used as a virtual machine provisioner - setting up machines, running any configuration on those machines and then exiting.

Other tools to test with

● cachier○ limit the amount coffee you drink waiting on a VM to build○ Caches gem, rpm, apt, and other Guest packages under ~/.

vagrant

● vagrant-vbguest○ Installs/Updates the host’s VirtualBox Guest Additions on the

guest.

Other plugins I use:

● https://github.com/adrienthebo/oscar ● https://www.virtualbox.org/ ● https://www.vagrantup.com/ ● Plug-ins

○ https://github.com/adrienthebo/vagrant-auto_network○ https://github.com/adrienthebo/vagrant-hosts ○ https://github.com/adrienthebo/vagrant-config_builder ○ https://github.com/adrienthebo/vagrant-pe_build ○ https://github.com/fgrehm/vagrant-cachier

● Other Presentations and documents○ http://www.slideshare.net/PuppetLabs/oscar-rapid-iteration-with-vagrant-and-puppet-enterprise○ http://www.youtube.com/watch?v=1TgGQjjLDXg ○ http://fgrehm.viewdocs.io/vagrant-cachier ○ http://puppet-vagrant-boxes.puppetlabs.com/

● Test tools○ http://serverspec.org/○ http://rspec-puppet.com/○ https://github.com/puppetlabs/beaker/wiki

● Github Example: https://github.com/jscelza/oscar_vagrant_example

Helpful Links and References:


Recommended