Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

salt.states.file.replace should honor user and group #8399

Closed
ruimarinho opened this issue Nov 11, 2013 · 2 comments · Fixed by #8417
Closed

salt.states.file.replace should honor user and group #8399

ruimarinho opened this issue Nov 11, 2013 · 2 comments · Fixed by #8417
Assignees
Labels
Bug broken, incorrect, or confusing behavior severity-low 4th level, cosemtic problems, work around exists

Comments

@ruimarinho
Copy link

Currently, salt.states.file.replace changes the ownership of the file that is being updated. I believe this state should honor the original user/group and additionally support the user and group parameters as most of the other file states.

I worked around this issue by using a file.managed state later on the process to manage the ownership.

@terminalmage
Copy link
Contributor

I've noticed this as well. The reason for this is that the old file is renamed to filename.bak and salt creates a new file. It should be also doing a chown after the fact to properly set ownershop. Should not be too difficult to fix.

@terminalmage
Copy link
Contributor

@ruimarinho Check out #8417, this should take care of it. Thanks again for reporting this. Like I said, this is something I had noticed, but I just hadn't gotten around to doing anything about it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug broken, incorrect, or confusing behavior severity-low 4th level, cosemtic problems, work around exists
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants