Cron Job is a feature that allows you to do continuous execution to run automatically by the server. Through a Cron Job, you can specify what you want to achieve. You can, for example, send an email newsletter on Sunday mornings at 9 am for all your clients. You make an order through a Cron Job and the server will do the job automatically. You also can ask the server to send You an email notification that the Cron Job is completed. This article describes how to create a Cron Job from the terminal SSH and how to set the order to receive the confirmation email.
Create A Cron Job. First, open a Terminal (if you use Linux) or Putty (if using Windows). then login with the username of your SSH and password.
Now type “crontab-e” command after it:
This will open a file where you will be able to add a Cron Job that want to be executed.
he command will look like the following:
* * * * * curl http://domain.com/cronjob
If you would like to add your email to receive notification each time you run Cron Job to be notes or knowing the Cron Job is running correctly, you can add this command:
Once you are done, press “ESC” to quit the edit mode ending. Or you can do a “Save” command with the keyboard: CTRL + O + ENTER. Then exit the editing area command with the keyboard: CTRL + E