User Tools

Site Tools


gen:automated_admin_tasks

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
gen:automated_admin_tasks [2025/04/16 06:39] kirtisinghgen:automated_admin_tasks [2025/04/17 05:50] (current) kirtisingh
Line 7: Line 7:
 Under the user (which has been enabled for admin tasks), create the folder /home///user///admin_tasks , if it is not already created . Substitute //user// for the admin task user Under the user (which has been enabled for admin tasks), create the folder /home///user///admin_tasks , if it is not already created . Substitute //user// for the admin task user
  
-Under the folder /home///user///admin_tasks , following sub-folders are involved+Under the folder **/home///user///admin_tasks** , following sub-folders are involved
  
-//new_tasks// - If it is not present, you will need to create it at your end. Here you would place the requisite JSON file with a .json extension which contains the task details . The JSON file should begin with a number preferably a timestamp . Example of a valid JSON filename is 1744610599.json . Each JSON file contains a single task. The typical fomat of a JSON file is +**//new_tasks//** - If it is not present, you will need to create it at your end. Here you would place the requisite JSON file with a .json extension which contains the task details . The JSON file should begin with a number preferably a timestamp . Example of a valid JSON filename is 1744610599.json . Each JSON file contains a single task. The typical fomat of a JSON file is 
  
 <code> <code>
Line 21: Line 21:
 </code> </code>
  
 +Click [[:json_Calls|this link]] to checkout various available JSON calls
  
 +The system checks for new tasks every minute, and the moves those tasks to the **//current_tasks//** folder before executing the task. 
  
 +**//current_tasks//** - This is a system created folder to manage the task state. When a task is to be executed, the system places it in this folder. When the execution is done, the task is then moved to either **//handled_tasks//** or **//discarded_tasks//** depending upon whether its execution was successful or not 
  
 +**//handled_tasks//** - Tasks which are successful, are placed under this folder
 +
 +**//discarded_tasks//** - Tasks which are un-successful, are placed under this folder. It also contains a log file w.r.t. task where its name begins using the same name of the original task file but with also date/time references.  
 +
 +----------------
 +
 +To summarise everthing
 +
 +As a developer, you would need be doing the following\\
 +- Enable Admin tasks\\
 +- Ensure folder **/home///user///admin_tasks** is present\\
 +- If you are placing tasks via a VHost's PHP script etc., you would need to expose the the above folder to the VHost from within N99panel options like [[:gen:accessing-parent-folders|Update Other Dirs]] under VHost details or 'Expose Dirs' from under Users\\
 +- Track the tasks using your own scripts
      
gen/automated_admin_tasks.1744785559.txt.gz · Last modified: 2025/04/16 06:39 by kirtisingh

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki