HomePhorge

Revert "Disable replace_file on Windows"
107d2e7857c2Unpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

Revert "Disable replace_file on Windows"

This reverts commit 4272d1f7674911c15da3ff6516d5827646a6bda6.

To quote:

Our current approach of setting owner/mode in the Puppet way risks
losing any extra permissions beyond owner/group/everyone, which is
significant enough that it is better to simply not support this
operation until we have a better solution. replace_file isn't used in
any code which actually runs on Windows at the moment, so this is
a benign change.

...except that it isn't so benign as all that: various other parts of the code
open-code the same method, poorly, and with various different bugs. They will
all, without question, lose permissions in exactly the same way on Windows.

At least by routing them through a central path we can start to unify their
behaviour and get to a place where fixing one point in the code fixes all the
faulty permission transfers that we previously had.

We win an overall net reduction in bug count, and an increase in
predictability of bugs, from this change.

Event Timeline

Daniel Pittman <daniel@puppetlabs.com> committed rPU107d2e7857c2: Revert "Disable replace_file on Windows" (authored by Daniel Pittman <daniel@puppetlabs.com>).Mar 30 2012, 9:15 PM