Skip to content

Instantly share code, notes, and snippets.

@cnk
Last active August 29, 2015 14:22
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 cnk/3e7934c5e9982a1bb89f to your computer and use it in GitHub Desktop.
Save cnk/3e7934c5e9982a1bb89f to your computer and use it in GitHub Desktop.
In the parent cookbook's attributes/default.rb:
default['dev-django-skeleton']['database']['host'] = "127.0.0.1"
In my wrapper cookbook's attributes/default.rb:
normal['dev-django-skeleton']['database']['host'] = "an RDS name"
In my kitchen.yml for the local Vagrant:
attributes: { dev-django-skeleton: { database: { host: "127.0.0.1" } } }
When I run 'kitchen converge'', this if statement is consistently evaluating to the RDS name:
if node['dev-django-skeleton']['database']['host'] == "127.0.0.1"....
@cnk
Copy link
Author

cnk commented May 27, 2015

Changing line 5 to be default['dev-django-skeleton']['database']['host'] = "an RDS name" allows the kitchen.yml attributes to override the database host attribute

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment