Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Info

This Article explains how to automate UK bank holiday timetable.

Created: July 2024

Updated: August 2024

Permalink:   https://wildix.atlassian.net/wiki/x/uBbOAQ


Table of Contents

Scenario

...

  • Execute the script weekly, the following will run the script every Tuesday at 00:05: 

    Code Block
    languagejs
    linenumberstrue
    05 0 * * 2 /usr/bin/python3 /home/admin/get_bankholidays.py

    You can use the crontab.guru website to help you set the frequency you want the script to run. 

Note

Once a schedule is configured in the crontab, it will overwrite any manual changes made to the timetable each time it runs.


  • To add this task to the crontab, in terminal logged in as root user run the following:  

    Code Block

...

  • crontab -e

    If you are asked to select an editor, select nano or nano-tiny as these are the most straightforward to use

  • Once you’re in the editor, it is a good idea to add a comment line to describe the purpose of the task, to do this start the line with #
  • Then on a new line insert the string:

...