Feature #49379
closedRun scheduler tasks with proper user
0%
Description
At the moment, scheduler tasks are run as administrator (or actually "currently logged-in user") when manually invoked in a TYPO3 Backend but run as _cli_scheduler when running by a cron job.
This leads to problem when scheduler tasks base record editing (insert/update/...) on the TYPO3 API (TCEmain) because running the task in Backend "works" but running it by cron job may fail as the _cli_scheduler user may not be granted proper access.
We should change the default behaviour, running a task manually should behave the same as running it by cron job, except that it runs in sync by the PHP module and allows easy debugging and error reporting, right into the Backend.
But sometimes, granting every single option to the _cli_scheduler user may not possible/wanted and the _cli_scheduler should then have a way, within EXT:scheduler to impersonate as another user, typically a TYPO3 administrator but possibly some other user.
What is suggested is to add a "run as" option for each and every task definition, similarly to the /etc/crontab
file on Linux which allows to use which user should run a given cron job. By default the _cli_scheduler user would be selected but a list of other users would be available (perhaps marked as "scheduler-aware" first).
Updated by Benni Mack about 9 years ago
- Target version changed from 7.5 to 8 LTS
Updated by Gerrit Code Review about 9 years ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/43584
Updated by Gerrit Code Review about 9 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/43584
Updated by Christian Kuhn over 8 years ago
- Status changed from Under Review to Rejected
rejected: there is no reliable solution to exec('php') on a wide band of systems.