Add ScheduledJobs to menu and remove future work section from jobs
This commit is contained in:
@@ -85,6 +85,8 @@ toc:
|
||||
path: /docs/user-guide/jobs/work-queue-1/
|
||||
- title: Fine Parallel Processing using a Work Queue
|
||||
path: /docs/user-guide/jobs/work-queue-2/
|
||||
- title: Scheduled Jobs
|
||||
path: /docs/user-guide/scheduled-jobs/
|
||||
|
||||
- title: Service Discovery and Load Balancing
|
||||
section:
|
||||
|
||||
@@ -19,6 +19,9 @@ A _Scheduled Job_ manages time based [Jobs](/docs/user-guide/jobs/), namely:
|
||||
One ScheduledJob object is like one line of a _crontab_ (cron table) file. It runs a job periodically
|
||||
on a given schedule, written in [Cron](https://en.wikipedia.org/wiki/Cron) format.
|
||||
|
||||
NOTE: The question mark (`?`) in the schedule has the same meaning as an asterisk `*`,
|
||||
that is, it stands for any of available value for a given field.
|
||||
|
||||
A typical use case is:
|
||||
|
||||
* Schedule a job execution at a given point in time.
|
||||
@@ -48,7 +51,7 @@ scheduledjob "hello" created
|
||||
Alternatively, use `kubectl run` to create a scheduled job without writing full config:
|
||||
|
||||
```shell
|
||||
$ kubectl run hello --schedule="0/1 * * * ?" --restart=OnFailure --image=busybox -- /bin/sh -c "date; echo Hello from the Kubernetes cluster"
|
||||
$ kubectl run hello --schedule="*/1 * * * *" --restart=OnFailure --image=busybox -- /bin/sh -c "date; echo Hello from the Kubernetes cluster"
|
||||
scheduledjob "hello" created
|
||||
```
|
||||
|
||||
@@ -57,7 +60,7 @@ After creating the scheduled job, get its status using this command:
|
||||
```shell
|
||||
$ kubectl get scheduledjob hello
|
||||
NAME SCHEDULE SUSPEND ACTIVE LAST-SCHEDULE
|
||||
hello 0/1 * * * ? False 0 <none>
|
||||
hello */1 * * * * False 0 <none>
|
||||
```
|
||||
|
||||
As you can see above, there's no active job yet, and no job has been scheduled, either.
|
||||
@@ -75,7 +78,7 @@ Now you've seen one running job scheduled by "hello". We can stop watching it an
|
||||
```shell
|
||||
$ kubectl get scheduledjob hello
|
||||
NAME SCHEDULE SUSPEND ACTIVE LAST-SCHEDULE
|
||||
hello 0/1 * * * ? False 0 Mon, 29 Aug 2016 14:34:00 -0700
|
||||
hello */1 * * * * False 0 Mon, 29 Aug 2016 14:34:00 -0700
|
||||
```
|
||||
|
||||
You should see that "hello" successfully scheduled a job at the time specified in `LAST-SCHEDULE`. There are
|
||||
|
||||
@@ -3,7 +3,7 @@ kind: ScheduledJob
|
||||
metadata:
|
||||
name: hello
|
||||
spec:
|
||||
schedule: 0/1 * * * ?
|
||||
schedule: "*/1 * * * *"
|
||||
jobTemplate:
|
||||
spec:
|
||||
template:
|
||||
|
||||
Reference in New Issue
Block a user