Aug 30 in DevOps
Q: What happens when you don’t specify a Resource’s action in Chef

1 Answer

0 votes
Aug 30
In case, if you don't specify a resource’s action, then Chef applies the default action.

For example, in resource 1, the action is not specified, still, it will take a default action.

file 'C:UsersAdministratorchef-reposettings.ini' do

content 'greeting=hello world'

end

In resource 2, when you define the action with create command, it is also used to create the default action.

file 'C:UsersAdministratorchef-reposettings.ini' do

action :create

content 'greeting=hello world'

end

Related questions

+1 vote
Apr 4, 2020 in Data Handling
0 votes
Oct 15, 2020 in DevOps
...