je le schéma suivant:Comment charger les attributs d'un fichier à chefspec noeud
attributes/default.rb
recipes/my_recipe.rb
spec/unit/recipes/my_recipe_spec.rb
Dans les fichiers attributs que j'ai beaucoup de paramètres communs aime
default['framework']['folder']['lib'] = '/usr/lib/fwrk'
Je voudrais utiliser dans mon chefspec, comme
it 'install the lib if there are changes' do
lib_path = chef_run.node['framework']['folder']['lib']
puts(lib_path)
end
Comment puis-je inclure ce fichier à mon noeud de SoloRunner/ServerRunner?
Oui, j'ai oublié d'exécuter 'converge' avant d'accéder au noeud –