Updating just one override


#1

Hi,

I currently use a command similar to the one below at the end of my build to
update my uat environment.

knife exec -E “environments.transform(‘name:uat’) { |n|
n.override_attributes ‘svr’=>{‘myapp’=>{‘version’=>’%build.number%’}}}”

It works fine although I have noticed that this call replaces all of my
overridden attributes rather than just the one I have specified in the call.
Is there a way to modify just one override attribute?

Cheers,

Florian


#2

Try:

knife exec -E “environments.transform(‘name:uat’) { |n|
node.override[‘foo’] = ‘bar’ }”

?

  • Julian

On Tue, Aug 27, 2013 at 4:29 AM, Florian Hehlen florian.hehlen@gmail.comwrote:

Hi,****


I currently use a command similar to the one below at the end of my build
to update my uat environment.****


knife exec -E “environments.transform(‘name:uat’) { |n|
n.override_attributes ‘svr’=>{‘myapp’=>{‘version’=>’%build.number%’}}}”***
*


It works fine although I have noticed that this call replaces all of my
overridden attributes rather than just the one I have specified in the
call. Is there a way to modify just one override attribute?****


Cheers,****

Florian****


[ Julian C. Dunn jdunn@aquezada.com * Sorry, I’m ]
[ WWW: http://www.aquezada.com/staff/julian * only Web 1.0 ]
[ gopher://sdf.org/1/users/keymaker/ * compliant! ]
[ PGP: 91B3 7A9D 683C 7C16 715F 442C 6065 D533 FDC2 05B9 ]