Skip to content

Commit

Permalink
chore: enable automountServiceAccountToken and refine examples for qu…
Browse files Browse the repository at this point in the history
…ick start. (#527)

Signed-off-by: Derek Wang <whynowy@gmail.com>
  • Loading branch information
whynowy authored and ashwinidulams committed Feb 14, 2023
1 parent ac33fb0 commit 8dc71a5
Show file tree
Hide file tree
Showing 18 changed files with 838 additions and 631 deletions.
28 changes: 28 additions & 0 deletions api/json-schema/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -17260,6 +17260,10 @@
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity",
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"imagePullSecrets": {
"description": "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod",
"items": {
Expand Down Expand Up @@ -17317,6 +17321,10 @@
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity",
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"containerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
Expand Down Expand Up @@ -17534,6 +17542,10 @@
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity",
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"containerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
Expand Down Expand Up @@ -18091,6 +18103,10 @@
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity",
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"bufferConfig": {
"description": "Optional configuration for the streams, consumers and buckets to be created in this JetStream service, if specified, it will be merged with the default configuration in numaflow-controller-config. It accepts a YAML format configuration, it may include 4 sections, \"stream\", \"consumer\", \"otBucket\" and \"procBucket\". Available fields under \"stream\" include \"retention\" (e.g. interest, limits, workerQueue), \"maxMsgs\", \"maxAge\" (e.g. 72h), \"replicas\" (1, 3, 5), \"duplicates\" (e.g. 5m). Available fields under \"consumer\" include \"ackWait\" (e.g. 60s) Available fields under \"otBucket\" include \"maxValueSize\", \"history\", \"ttl\" (e.g. 72h), \"maxBytes\", \"replicas\" (1, 3, 5). Available fields under \"procBucket\" include \"maxValueSize\", \"history\", \"ttl\" (e.g. 72h), \"maxBytes\", \"replicas\" (1, 3, 5).",
"type": "string"
Expand Down Expand Up @@ -18214,6 +18230,10 @@
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity",
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"backoffLimit": {
"description": "Specifies the number of retries before marking this job failed. More info: https://kubernetes.io/docs/concepts/workloads/controllers/job/#pod-backoff-failure-policy Numaflow defaults to 20",
"format": "int32",
Expand Down Expand Up @@ -18369,6 +18389,10 @@
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity",
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"imagePullSecrets": {
"description": "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod",
"items": {
Expand Down Expand Up @@ -19054,6 +19078,10 @@
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity",
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"containerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
Expand Down
28 changes: 28 additions & 0 deletions api/openapi-spec/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -17265,6 +17265,10 @@
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/",
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"imagePullSecrets": {
"description": "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod",
"type": "array",
Expand Down Expand Up @@ -17325,6 +17329,10 @@
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/",
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"containerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
Expand Down Expand Up @@ -17539,6 +17547,10 @@
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/",
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"containerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
Expand Down Expand Up @@ -18087,6 +18099,10 @@
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/",
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"bufferConfig": {
"description": "Optional configuration for the streams, consumers and buckets to be created in this JetStream service, if specified, it will be merged with the default configuration in numaflow-controller-config. It accepts a YAML format configuration, it may include 4 sections, \"stream\", \"consumer\", \"otBucket\" and \"procBucket\". Available fields under \"stream\" include \"retention\" (e.g. interest, limits, workerQueue), \"maxMsgs\", \"maxAge\" (e.g. 72h), \"replicas\" (1, 3, 5), \"duplicates\" (e.g. 5m). Available fields under \"consumer\" include \"ackWait\" (e.g. 60s) Available fields under \"otBucket\" include \"maxValueSize\", \"history\", \"ttl\" (e.g. 72h), \"maxBytes\", \"replicas\" (1, 3, 5). Available fields under \"procBucket\" include \"maxValueSize\", \"history\", \"ttl\" (e.g. 72h), \"maxBytes\", \"replicas\" (1, 3, 5).",
"type": "string"
Expand Down Expand Up @@ -18210,6 +18226,10 @@
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/",
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"backoffLimit": {
"description": "Specifies the number of retries before marking this job failed. More info: https://kubernetes.io/docs/concepts/workloads/controllers/job/#pod-backoff-failure-policy Numaflow defaults to 20",
"type": "integer",
Expand Down Expand Up @@ -18365,6 +18385,10 @@
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/",
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"imagePullSecrets": {
"description": "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod",
"type": "array",
Expand Down Expand Up @@ -19036,6 +19060,10 @@
"description": "The pod's scheduling constraints More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/",
"$ref": "#/definitions/io.k8s.api.core.v1.Affinity"
},
"automountServiceAccountToken": {
"description": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.",
"type": "boolean"
},
"containerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -398,6 +398,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
bufferConfig:
type: string
containerTemplate:
Expand Down Expand Up @@ -1367,6 +1369,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
imagePullSecrets:
items:
properties:
Expand Down
6 changes: 6 additions & 0 deletions config/base/crds/full/numaflow.numaproj.io_pipelines.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -490,6 +490,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down Expand Up @@ -1251,6 +1253,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
backoffLimit:
format: int32
type: integer
Expand Down Expand Up @@ -1872,6 +1876,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down
2 changes: 2 additions & 0 deletions config/base/crds/full/numaflow.numaproj.io_vertices.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down
12 changes: 12 additions & 0 deletions config/install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
bufferConfig:
type: string
containerTemplate:
Expand Down Expand Up @@ -1366,6 +1368,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
imagePullSecrets:
items:
properties:
Expand Down Expand Up @@ -2740,6 +2744,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down Expand Up @@ -3501,6 +3507,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
backoffLimit:
format: int32
type: integer
Expand Down Expand Up @@ -4122,6 +4130,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down Expand Up @@ -7592,6 +7602,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down
12 changes: 12 additions & 0 deletions config/namespace-install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
bufferConfig:
type: string
containerTemplate:
Expand Down Expand Up @@ -1366,6 +1368,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
imagePullSecrets:
items:
properties:
Expand Down Expand Up @@ -2740,6 +2744,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down Expand Up @@ -3501,6 +3507,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
backoffLimit:
format: int32
type: integer
Expand Down Expand Up @@ -4122,6 +4130,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down Expand Up @@ -7592,6 +7602,8 @@ spec:
type: array
type: object
type: object
automountServiceAccountToken:
type: boolean
containerTemplate:
properties:
env:
Expand Down
12 changes: 12 additions & 0 deletions docs/APIs.md
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,18 @@ empty definition that uses the default runtime handler. More info:
</p>
</td>
</tr>
<tr>
<td>
<code>automountServiceAccountToken</code></br> <em> bool </em>
</td>
<td>
<em>(Optional)</em>
<p>
AutomountServiceAccountToken indicates whether a service account token
should be automatically mounted.
</p>
</td>
</tr>
</tbody>
</table>
<h3 id="numaflow.numaproj.io/v1alpha1.AbstractVertex">
Expand Down
4 changes: 4 additions & 0 deletions examples/0-isbsvc-jetstream.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ metadata:
spec:
jetstream:
version: latest # Do NOT use "latest" in real deployment, check "numaflow-controller-config" ConfigMap to get available versions.
# Optional. Specifying "persistence" will create a PersistentVolumeClaim for data persistence, it works for most of Kubernetes
# clusters, including Kind, Minikube, K3s, etc, it's needed to run production workloads.
persistence:
volumeSize: 3Gi
8 changes: 8 additions & 0 deletions examples/2-even-odd-pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,26 @@ spec:
source:
http: {}
- name: even-or-odd
scale:
min: 1
udf:
container:
# Tell the input number is even or odd, see https://github.com/numaproj/numaflow-go/tree/main/pkg/function/examples/even_odd
image: quay.io/numaio/numaflow-go/map-even-odd
- name: even-sink
scale:
min: 1
sink:
# A simple log printing sink
log: {}
- name: odd-sink
scale:
min: 1
sink:
log: {}
- name: number-sink
scale:
min: 1
sink:
log: {}
edges:
Expand Down
Loading

0 comments on commit 8dc71a5

Please sign in to comment.