Overview on Cron job and Pipes Scheduling
Cron is the name of a program that enables unix users to execute commands or scripts (groups of commands) automatically at a specified time and/or date. A task to be automatically executed by Cron is called a cron job.
In WP Pipes system, the scheduling of your pipes is entrusted to a crone job. Cron will execute the pipes in your WordPress system by running a script. The link to this script is provided in Pipes >> Settings.
Setting up a Cron job to schedule pipes auto posting
You can choose to schedule Pipes automatic posting by running this cron job as script-side, which means you let Pipes take care of calling and executing this script. Or you can set it up to run as server-side, which means you set it up as a job for the cron on your server.
Before setting them up to run automatically, please make sure that all the pipes on your WordPress site run smoothly. A broken pipe may return a warning and stop the whole running process. Please also check the system requirements in Settings page of WPPipes to ensure that you’ve set up a suitable environment for Pipes.
Running your cron job as server-side
To run your cron job on the server side, access Pipes>>Settings and turn off cron job on the script side by choosing <<No, I want to run my Pipes Manually>> and hit <<Save changes>>.
This instruction is for hosting administrated with cPanel. But it’s pretty similar to other server administrators as well.
Step 1: Access your cPanel. You will see an icon leading to the page where you can set up your cron jobs.
Step 2: Creating a cron job for Pipes scheduling. In the setup page of your cron job, you will see this on your screen.
This is where you set the time interval for the schedule of your pipes. You can set them to run weekly, monthly, daily, or once in a few hours or minutes.
The Command box is where you input the command to make cron do your job. There are 2 commands that you can use. One is:
<pre>/bin/wget -O /dev/null “http://yourwordpresssite.com/?pipes=cron&task=callaio”</pre>
Replace the path in this command with the one you found in Pipes>>Settings, paste it into the Command box and hit <<Add New Cron Job>>. Your server will take care of running Pipes script, following the schedule you’ve just set, and your pipes will automatically run accordingly.
In case the command above does not work, you can use this command instead:
<pre>lynx -dump ‘http://yourwordpresssite.com/?pipes=cron&task=callaio'</pre>
Of course you will also have to edit the link in this command with the one in your Pipes>>Settings page.
Running your cron job as script-side
To run your cron job on the script side, just configure the Pipes Settings as shown in the picture below: