Skip to content

Instantly share code, notes, and snippets.

@hailwood
Created May 2, 2014 02:23
Show Gist options
  • Select an option

  • Save hailwood/56e7a8f60ba12796b357 to your computer and use it in GitHub Desktop.

Select an option

Save hailwood/56e7a8f60ba12796b357 to your computer and use it in GitHub Desktop.
node[:deploy].each do |application, deploy|
#in this context deploy refers to the specific application being deployed
#a default attribute can ben accessed via node[:key] as you would expect
#the issue being that we cannot override an attribute based on the specific application being deployed
#I am looking for a way to say "if the deploy node has the attribute e.g. deploy[:api][:key] use that
#otherwise fall back to node[:api][:key]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment