You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you change the config_path attribute to point to something other than the /etc/backup default then the deploy will fail. Reason being, derived attributes aren't updated when the attributes they make use of get updated. In order for the value to be set correctly you either have to manually set the derived attribute in addtion to config_path, or use a role or environment. Since I'm using chef-solo I also have the option of setting config_path directly in the node file, but I'd like to avoid the duplication.
As mentioned in this blog post on derived attributes, an easy fix is to simply change model_path to be a variable that gets computed in the default recipe.
The text was updated successfully, but these errors were encountered:
nozpheratu
changed the title
Can we make model_path a variable?
model_path doesn't update when config_path is modified in wrapper cookbok
Jan 7, 2015
The
model_path
is currently being computed based on theconfig_path
value as seen below:If you change the
config_path
attribute to point to something other than the/etc/backup
default then the deploy will fail. Reason being, derived attributes aren't updated when the attributes they make use of get updated. In order for the value to be set correctly you either have to manually set the derived attribute in addtion toconfig_path
, or use a role or environment. Since I'm using chef-solo I also have the option of settingconfig_path
directly in the node file, but I'd like to avoid the duplication.As mentioned in this blog post on derived attributes, an easy fix is to simply change
model_path
to be a variable that gets computed in the default recipe.The text was updated successfully, but these errors were encountered: