FluidTYPO3 / vhs

TYPO3 extension VHS: Fluid ViewHelpers
https://fluidtypo3.org
Other
190 stars 229 forks source link

Fixed possible permission problem with cache:flush #1727

Closed schoeppe closed 2 years ago

schoeppe commented 3 years ago

The touch command only succeeds if the process user is the file owner. This must not be true in some deployment scenarios: The deployment user is allowed to write (and delete) such cache files but must not be the owner.

The workaround is to recreate the cache file (in an atomic operation) with the same contents and touch the newly created file.

See FluidTYPO3#1509.

NamelessCoder commented 2 years ago

Thanks for the solution, @schoeppe :)