Skip to content

Commit 6c15a2d

Browse files
authored
docs(job_defintion): add cron (#2464)
* docs(job_defintion): add cron * fix indent
1 parent f0d34ef commit 6c15a2d

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

docs/resources/job_definition.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,11 @@ resource scaleway_job_definition main {
2323
env = {
2424
foo: "bar"
2525
}
26+
27+
cron {
28+
schedule = "5 4 1 * *" # cron at 04:05 on day-of-month 1
29+
timezone = "Europe/Paris"
30+
}
2631
}
2732
```
2833

@@ -38,6 +43,9 @@ The following arguments are supported:
3843
- `command` - (Optional) The command that will be run in the container if specified.
3944
- `timeout` - (Optional) The job run timeout, in Go Time format (ex: `2h30m25s`)
4045
- `env` - (Optional) The environment variables of the container.
46+
- `cron` - (Optional) The cron configuration
47+
- `schedule` - Cron format string.
48+
- `timezone` - The timezone, must be a canonical TZ identifier as found in this [list](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
4149
- `region` - (Defaults to [provider](../index.md#region) `region`) The [region](../guides/regions_and_zones.md#regions) of the Job.
4250
- `project_id` - (Defaults to [provider](../index.md#project_id) `project_id`) The ID of the project the Job is associated with.
4351

@@ -46,7 +54,8 @@ The following arguments are supported:
4654
In addition to all arguments above, the following attributes are exported:
4755

4856
- `id` - The ID of the Job Definition.
49-
~> **Important:** Serverless Jobs Definition's IDs are [regional](../guides/regions_and_zones.md#resource-ids), which means they are of the form `{region}/{id}`, e.g. `fr-par/11111111-1111-1111-1111-111111111111
57+
58+
~> **Important:** Serverless Jobs Definition's IDs are [regional](../guides/regions_and_zones.md#resource-ids), which means they are of the form `{region}/{id}`, e.g. `fr-par/11111111-1111-1111-1111-111111111111`
5059

5160
## Import
5261

0 commit comments

Comments
 (0)