Ansible tasks should set explicit file permissions #1342
Labels
good first issue
Denotes an issue ready for a new contributor, according to the "help wanted" guidelines.
help wanted
Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.
kind/bug
Categorizes issue or PR as related to a bug.
What steps did you take and what happened:
Run
make -C images/capi lint
and notice that the project is ignoring a few linter warnings of the typerisky-file-permissions: File permissions unset or incorrect.
See here for details.Fixing this usually involves setting an appropriate Linux permission on a resource. This is generally
0755
for directories and0644
for files, but each case needs to be looked at individually.There are also cases where files are being deleted (which shouldn't require permissions to be explicit), but the linter can't tell that since the
state:
field is being populated from a loop variable. That can be refactored sostate: absent
is hard-coded.What did you expect to happen:
The linter shouldn't report any of this type of warning.
Anything else you would like to add:
Here's one way to fix it:
/kind bug
The text was updated successfully, but these errors were encountered: