cron
0 9 1 * *SSH Authorized Keys Audit — 1st of Month
“At 09:00, on day 1 of the month”
Monthly audit of all SSH authorized_keys files across all user home directories. Identifies unauthorized keys, keys without comments (unknown origin), and orphaned keys for deprovisioned employees.
Monthly1 per month runs/day
Want to customize this schedule or validate your own cron expression?
Try it live →Field Breakdown
| Field | Value | Meaning |
|---|---|---|
| minute | 0 | 0 |
| hour | 9 | 9 |
| day | 1 | 1 |
| month | * | every month |
| weekday | * | every day of week |
0
minute
9
hour
1
day
*
month
*
weekday
Common Use Cases
- ✓SSH key audit monthly
- ✓authorized_keys review cron
- ✓Orphaned SSH key detection
- ✓SSH access control audit
Code Examples
Bash / crontab
# Run your script on schedule: 0 9 1 * * 0 9 1 * * /path/to/your/script.sh
Node.js (node-cron)
import cron from 'node-cron';
cron.schedule('0 9 1 * *', () => {
console.log('Running scheduled task');
});Python (APScheduler)
from apscheduler.schedulers.blocking import BlockingScheduler
scheduler = BlockingScheduler()
@scheduler.scheduled_job('cron', minute='0', hour='9', day='1')
def my_job():
print('Running scheduled task')
scheduler.start()GitHub Actions Workflow
Generate a ready-to-use .github/workflows/schedule.yml file. Customize the name and download directly.
GitHub Actions
# .github/workflows/schedule.yml
name: SSH Authorized Keys Audit — 1st of Month
on:
schedule:
- cron: '0 9 1 * *'
workflow_dispatch: # allow manual trigger
jobs:
run:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Run scheduled task
run: |
echo "Running on schedule: 0 9 1 * *"
# Add your commands here
Save as .github/workflows/schedule.yml in your repository root
Cron Syntax Quick Reference
| Field | Allowed Values | Special Chars |
|---|---|---|
| minute | 0–59 | * , - / |
| hour | 0–23 | * , - / |
| day of month | 1–31 | * , - / |
| month | 1–12 or JAN–DEC | * , - / |
| day of week | 0–7 or SUN–SAT | * , - / |
Special characters: *= any value ,= list -= range / = step
Related Patterns — Monthly
Need to build your own cron expression from scratch?
Open the Cron Expression Builder →