I have a git repo where a workflow file called build.yml(which builds the project, and triggers iac pipeline that deploys my application in AWS resources) is set up under github Actions. This workflow is triggered when a commit/code push happened to the default branch. But code commits to this repo happens rarely. I want to trigger this workflow regularly say once in every month to trigger build and redeploy AWS resources(with updated patches from org level) via Actions.
Presently I am triggering the Actions workflow by Manually pushing an empty commit to the default branch.
Looking for a way to automatically push an empty commit to my default branch from github Actions at regular intervals using schedule cron from Actions workflow. Any pointers for the same?
I am able use the scheduler in Actions workflow using schedule cron as below, But need to push an empty commit to the default branch at that frequency
push:
branches: [main]
schedule:
- cron: '30 3 10 * *'