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
I have one case for file.managed, where salt self changes the default value of replace from True to False, printing this warning
[WARNING ] State for file: /boot/efi/EFI/centos/grub.cfg - Neither 'source' nor 'contents' nor 'contents_pillar' nor 'contents_grains' was defined, yet 'replace' was set to 'True'. As there is no source to replace the file with, 'replace' has been set to 'False' to avoid reading the file unnecessarily.
We are changing here only the file mode and ownership so there is no need of replacing the file.
In order to implement this rule we could render the states as YAML and just check if 'source' nor 'contents' nor 'contents_pillar' nor 'contents_grains' was defined.
roaldnefs
changed the title
Check file.managed replacement need
Feature Request: Check file.managed replacement need
Jan 29, 2021
Hi,
I have one case for file.managed, where salt self changes the default value of replace from True to False, printing this warning
We are changing here only the file mode and ownership so there is no need of replacing the file.
problematic state:
fixed state:
The text was updated successfully, but these errors were encountered: