Runing A Scheduled task (cron)
-
Hey there! I am a bit confused as to how to setup a cron in terminal. Or im assuming thats where you set it up.
I am running a wordpress app and i need to setup a cron job to import data from google calander for a plugin. I was directed to the addon section of cloudron but am a bit confused as to where to run this code.
Do I just paste it into my apps terminal after modifying the appropriate lines?
After reading the overview it just points to this manifest page which is blank....
Also for the schedule feild what would a correct line look like for running the task every 10 minutes? Link this?
"import_google_events": { "schedule": "10 * * * *", "command": "//app/data/wp-content/plugins/modern-events-calendar/app/crons/g-import.php" } }
Just looking for some direction on how to setup cron tasks! thanks!```
code_text -
@affinity The addon section is meant for app packaging/developers and not for end users. The manifest cannot be change at run time, it is something that is set at compile time.
The wordpress app already runs the WP cron event every 5 minutes. You can use a plugin like https://wordpress.org/plugins/wp-crontrol/ to add custom cron events inside wordpress itself. Does that work for you?