Skip to content

Commit

Permalink
feat: customize init-container resources. Closes #303 (#304)
Browse files Browse the repository at this point in the history
Signed-off-by: David Seapy <dseapy@gmail.com>
  • Loading branch information
dseapy authored and whynowy committed Nov 7, 2022
1 parent 61cf227 commit 448127f
Show file tree
Hide file tree
Showing 24 changed files with 2,525 additions and 448 deletions.
12 changes: 12 additions & 0 deletions api/json-schema/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -17325,6 +17325,9 @@
"x-kubernetes-patch-merge-key": "name",
"x-kubernetes-patch-strategy": "merge"
},
"initContainerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
"initContainers": {
"description": "List of init containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/",
"items": {
Expand Down Expand Up @@ -17510,6 +17513,9 @@
"x-kubernetes-patch-merge-key": "name",
"x-kubernetes-patch-strategy": "merge"
},
"initContainerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
"metadata": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.Metadata",
"description": "Metadata sets the pods's metadata, i.e. annotations and labels"
Expand Down Expand Up @@ -18340,6 +18346,9 @@
"x-kubernetes-patch-merge-key": "name",
"x-kubernetes-patch-strategy": "merge"
},
"initContainerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
"metadata": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.Metadata",
"description": "Metadata sets the pods's metadata, i.e. annotations and labels"
Expand Down Expand Up @@ -18921,6 +18930,9 @@
"x-kubernetes-patch-merge-key": "name",
"x-kubernetes-patch-strategy": "merge"
},
"initContainerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
"initContainers": {
"description": "List of init containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/",
"items": {
Expand Down
12 changes: 12 additions & 0 deletions api/openapi-spec/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -17333,6 +17333,9 @@
"x-kubernetes-patch-merge-key": "name",
"x-kubernetes-patch-strategy": "merge"
},
"initContainerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
"initContainers": {
"description": "List of init containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/",
"type": "array",
Expand Down Expand Up @@ -17515,6 +17518,9 @@
"x-kubernetes-patch-merge-key": "name",
"x-kubernetes-patch-strategy": "merge"
},
"initContainerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
"metadata": {
"description": "Metadata sets the pods's metadata, i.e. annotations and labels",
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.Metadata"
Expand Down Expand Up @@ -18336,6 +18342,9 @@
"x-kubernetes-patch-merge-key": "name",
"x-kubernetes-patch-strategy": "merge"
},
"initContainerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
"metadata": {
"description": "Metadata sets the pods's metadata, i.e. annotations and labels",
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.Metadata"
Expand Down Expand Up @@ -18903,6 +18912,9 @@
"x-kubernetes-patch-merge-key": "name",
"x-kubernetes-patch-strategy": "merge"
},
"initContainerTemplate": {
"$ref": "#/definitions/io.numaproj.numaflow.v1alpha1.ContainerTemplate"
},
"initContainers": {
"description": "List of init containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/",
"type": "array",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1372,6 +1372,151 @@ spec:
type: string
type: object
type: array
initContainerTemplate:
properties:
env:
items:
properties:
name:
type: string
value:
type: string
valueFrom:
properties:
configMapKeyRef:
properties:
key:
type: string
name:
type: string
optional:
type: boolean
required:
- key
type: object
fieldRef:
properties:
apiVersion:
type: string
fieldPath:
type: string
required:
- fieldPath
type: object
resourceFieldRef:
properties:
containerName:
type: string
divisor:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
resource:
type: string
required:
- resource
type: object
secretKeyRef:
properties:
key:
type: string
name:
type: string
optional:
type: boolean
required:
- key
type: object
type: object
required:
- name
type: object
type: array
imagePullPolicy:
type: string
resources:
properties:
limits:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
type: object
requests:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
type: object
type: object
securityContext:
properties:
allowPrivilegeEscalation:
type: boolean
capabilities:
properties:
add:
items:
type: string
type: array
drop:
items:
type: string
type: array
type: object
privileged:
type: boolean
procMount:
type: string
readOnlyRootFilesystem:
type: boolean
runAsGroup:
format: int64
type: integer
runAsNonRoot:
type: boolean
runAsUser:
format: int64
type: integer
seLinuxOptions:
properties:
level:
type: string
role:
type: string
type:
type: string
user:
type: string
type: object
seccompProfile:
properties:
localhostProfile:
type: string
type:
type: string
required:
- type
type: object
windowsOptions:
properties:
gmsaCredentialSpec:
type: string
gmsaCredentialSpecName:
type: string
hostProcess:
type: boolean
runAsUserName:
type: string
type: object
type: object
type: object
metadata:
properties:
annotations:
Expand Down
Loading

0 comments on commit 448127f

Please sign in to comment.