Bug 14712

Summary: Feature for controlling cron jobs/cmd line scripts from staff client
Product: Koha Reporter: Eivin Giske Skaaren <eivin>
Component: Command-line UtilitiesAssignee: Eivin Giske Skaaren <eivin>
Status: CLOSED WONTFIX QA Contact: Testopia <testopia>
Severity: new feature    
Priority: P5 - low CC: dcook, p.thrasher, robin
Version: unspecified   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=1993
Change sponsored?: Sponsored Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:

Description Eivin Giske Skaaren 2015-08-24 16:11:22 UTC
This feature will add an admin page to the staff client enabling superusers to trigger cron or other scripts without having to rely on a server admin.
Comment 1 Eivin Giske Skaaren 2015-08-24 16:12:39 UTC
Sponsored-by: Halland county library
Comment 2 David Cook 2016-02-16 02:41:01 UTC
Hi Eivin, 

Do you have some code prepared for this already? I've also been working on a new task scheduler, which I'm putting the finishing touches on at the moment.
Comment 3 Eivin Giske Skaaren 2016-02-16 10:33:23 UTC
Hi David,

I did some initial work on this but it was abandoned for now because of the security aspect. Exposing root shell via CGI might not be a good idea.

If you have a good solution that also perhaps solves some of the things that we wanted to solve with this I would be happy to test/sign-off your patch.
Comment 4 David Cook 2016-02-16 23:48:10 UTC
(In reply to Eivin Giske Skaaren from comment #3)
> Hi David,
> 
> I did some initial work on this but it was abandoned for now because of the
> security aspect. Exposing root shell via CGI might not be a good idea.
> 
> If you have a good solution that also perhaps solves some of the things that
> we wanted to solve with this I would be happy to test/sign-off your patch.

Thanks for the update. 

Basically, I've just written a task scheduler, which uses pluggable modules to run tasks. At the moment, I'm using it for downloading OAI-PMH records and importing OAI-PMH records into Koha. Adding support for things like "scheduled reports" would be as easy as creating a task plugin and creating a data entry template on the Koha staff client.

At the moment, all the work is on bug #10662, but I've thought about splitting my patches into separate bug reports...
Comment 5 Eivin Giske Skaaren 2016-03-09 21:56:46 UTC
I am closing this as it is not realistic when considering security aspects etc. to develop this feature for the sponsor with the timebank available.

I would suggest that any further efforts perhaps is best directed at Davids task scheduler.