On 12/3/2012 5:57 AM, Schofield wrote:
Thanks for the great response James.  I think you have done exactly what
I am looking to do.  I want to ask more about controlling the versions
of the application packages in hiera.  I have multiple different dev
groups who each work on different release schedules.  I don't want to
have operations/puppet folks involved with every release as application
versions move through dev/test/prod.  So how would one go about letting
dev teams control which versions of applications are mapped to which
environments?

We have a set of machines that we spin up per event. Use a custom AMI and let Puppet add the final 1-2% of config to catch anything that's changed recently. Puppet runs only once and the machines spin down after 4-10 hours. The custom app code doesn't change often which seemed like a decent candidate for letting the Dev team push versions to Puppet. Here's how it works

Hiera can't search two different dir trees for the same backend so I set up a second backend, json. Mostly do this so I have final say via yaml on versions/config. Probably overkill.

hiera.yaml
---
:hierarchy:
    - %{clientcert}
    - %{environment}/%{role}/%{calling_module}
    - %{environment}/%{role}
    - %{calling_module}
    - %{role}
    - %{environment}
    - common

:backends:
    - yaml
    - json

:yaml:
    :datadir: '/puppet/etc/environments/%{environment}/hieradata'

:json:
    :datadir: '/puppet/data/%{environment}/hieradata'

/puppet/data/production/hieradata/mycode.json
{"mycode_ensure":"latest","mycode_version":"somebranch-12-11-27"}

When Dev does a release they update a set of core machines via Capistrano and then push the new version into Puppet do the ephemeral machines will check out the latest version when they spin up.

I've been meaning to extend the idea as well as move to more of a pull method for software release, but it hasn't been pressing.

Ramin

--
You received this message because you are subscribed to the Google Groups "Puppet 
Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to