Skip to content

Commit c08be42

Browse files
thomas-tacquetSamyOubouaziz
authored andcommitted
feat(serverles): add more cron in cheatsheet (scaleway#4496)
* feat(serverles): add more cron in cheatsheet * Update macros/serverless/cron-schedules.mdx --------- Co-authored-by: SamyOubouaziz <[email protected]>
1 parent e662bba commit c08be42

File tree

1 file changed

+24
-5
lines changed

1 file changed

+24
-5
lines changed

macros/serverless/cron-schedules.mdx

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ Cron jobs are expressed using the `* * * * *` format, which corresponds to the f
1010

1111
```
1212
┌───────────── minute
13-
│ ┌───────────── hour
14-
│ │ ┌───────────── day of the month
15-
│ │ │ ┌───────────── month
13+
│ ┌───────────── hour
14+
│ │ ┌───────────── day of the month
15+
│ │ │ ┌───────────── month
1616
│ │ │ │ ┌───────────── day of the week
17-
│ │ │ │ │
17+
│ │ │ │ │
1818
│ │ │ │ │
1919
│ │ │ │ │
2020
* * * * *
@@ -50,6 +50,25 @@ Several operators can be added to each field to further refine your schedule.
5050

5151
## Cron schedule examples
5252

53+
### Simple
54+
55+
Some examples of simple cron schedules expressions, useful for tasks like regular backups or file analysis.
56+
57+
| Cron expression | Description |
58+
|----------------------------|----------------------------------------------------------------|
59+
| `* * * * *` | Runs every minute |
60+
| `*/5 * * * *` | Runs every 5 minutes |
61+
| `*/15 * * * *` | Runs every 15 minutes |
62+
| `0 * * * *` | Runs every hour |
63+
| `0 0 * * *` | Runs every day at midnight |
64+
| `0 9 * * *` | Runs every day at 9:00 |
65+
| `0 0 * * 0` | Runs every Sunday at midnight |
66+
| `0 0 1 * *` | Runs once a month at midnight |
67+
68+
### Advanced
69+
70+
Advanced example for more specific use cases.
71+
5372
| Cron expression | Description |
5473
|----------------------------|----------------------------------------------------------------|
5574
| `0 12 * * *` | Runs at 12:00 (noon) every day |
@@ -68,4 +87,4 @@ Several operators can be added to each field to further refine your schedule.
6887

6988
- Serverless Functions and Serverless Containers [CRON triggers](/serverless-functions/concepts#cron-trigger) use the **UTC** time zone. This parameter cannot be modified.
7089

71-
- Serverless Jobs allow modifying the time zone of their schedules via the Job **Settings** tab. Refer to [the job scheduling documentation](/serverless-jobs/how-to/manage-job-schedule/) for more information.
90+
- Serverless Jobs allow modifying the time zone of their schedules via the Job **Settings** tab. Refer to [the job scheduling documentation](/serverless-jobs/how-to/manage-job-schedule/) for more information.

0 commit comments

Comments
 (0)