Add kubeflow/v1.10.0
This commit is contained in:
@@ -2,46 +2,46 @@ apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
namespace: kubeflow
|
||||
resources:
|
||||
- ../../pipeline
|
||||
- ../../cache
|
||||
- ../../cache-deployer
|
||||
- pipeline-install-config.yaml
|
||||
- mysql-secret.yaml
|
||||
- ../../pipeline
|
||||
- ../../cache
|
||||
- ../../cache-deployer
|
||||
- pipeline-install-config.yaml
|
||||
- mysql-secret.yaml
|
||||
vars:
|
||||
- name: kfp-namespace
|
||||
objref:
|
||||
kind: Deployment
|
||||
apiVersion: apps/v1
|
||||
name: ml-pipeline
|
||||
fieldref:
|
||||
fieldpath: metadata.namespace
|
||||
- name: kfp-app-name
|
||||
objref:
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
apiVersion: v1
|
||||
fieldref:
|
||||
fieldpath: data.appName
|
||||
- name: kfp-app-version
|
||||
objref:
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
apiVersion: v1
|
||||
fieldref:
|
||||
fieldpath: data.appVersion
|
||||
- name: kfp-artifact-bucket-name
|
||||
objref:
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
apiVersion: v1
|
||||
fieldref:
|
||||
fieldpath: data.bucketName
|
||||
- name: kfp-default-pipeline-root
|
||||
objref:
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
apiVersion: v1
|
||||
fieldref:
|
||||
fieldpath: data.defaultPipelineRoot
|
||||
- fieldref:
|
||||
fieldPath: metadata.namespace
|
||||
name: kfp-namespace
|
||||
objref:
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
name: ml-pipeline
|
||||
- fieldref:
|
||||
fieldPath: data.appName
|
||||
name: kfp-app-name
|
||||
objref:
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
- fieldref:
|
||||
fieldPath: data.appVersion
|
||||
name: kfp-app-version
|
||||
objref:
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
- fieldref:
|
||||
fieldPath: data.bucketName
|
||||
name: kfp-artifact-bucket-name
|
||||
objref:
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
- fieldref:
|
||||
fieldPath: data.defaultPipelineRoot
|
||||
name: kfp-default-pipeline-root
|
||||
objref:
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
configurations:
|
||||
- params.yaml
|
||||
- params.yaml
|
||||
|
||||
+3
-3
@@ -11,7 +11,7 @@ data:
|
||||
until the changes take effect. A quick way to restart all deployments in a
|
||||
namespace: `kubectl rollout restart deployment -n <your-namespace>`.
|
||||
appName: pipeline
|
||||
appVersion: 2.2.0
|
||||
appVersion: 2.5.0
|
||||
dbHost: mysql # relic to be removed after release
|
||||
dbPort: "3306" # relic to be removed after release
|
||||
dbType: mysql
|
||||
@@ -63,8 +63,8 @@ data:
|
||||
## cacheImage is the image that the mutating webhook will use to patch
|
||||
## cached steps with. Will be used to echo a message announcing that
|
||||
## the cached step result will be used. If not set it will default to
|
||||
## 'gcr.io/google-containers/busybox'
|
||||
cacheImage: "gcr.io/google-containers/busybox"
|
||||
## 'registry.k8s.io/busybox'
|
||||
cacheImage: "registry.k8s.io/busybox"
|
||||
## cacheNodeRestrictions the dummy container runing if output is cached
|
||||
## will run with the same affinity and node selector as the default pipeline
|
||||
## step. This is defaulted to 'false' to allow the pod to be scheduled on
|
||||
|
||||
+21
-21
@@ -8,40 +8,40 @@ resources:
|
||||
- pipeline-install-config.yaml
|
||||
- postgres-secret-extended.yaml
|
||||
vars:
|
||||
- name: kfp-namespace
|
||||
- fieldref:
|
||||
fieldPath: metadata.namespace
|
||||
name: kfp-namespace
|
||||
objref:
|
||||
kind: Deployment
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
name: ml-pipeline
|
||||
fieldref:
|
||||
fieldpath: metadata.namespace
|
||||
- name: kfp-app-name
|
||||
- fieldref:
|
||||
fieldPath: data.appName
|
||||
name: kfp-app-name
|
||||
objref:
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
apiVersion: v1
|
||||
fieldref:
|
||||
fieldpath: data.appName
|
||||
- name: kfp-app-version
|
||||
- fieldref:
|
||||
fieldPath: data.appVersion
|
||||
name: kfp-app-version
|
||||
objref:
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
apiVersion: v1
|
||||
fieldref:
|
||||
fieldpath: data.appVersion
|
||||
- name: kfp-artifact-bucket-name
|
||||
- fieldref:
|
||||
fieldPath: data.bucketName
|
||||
name: kfp-artifact-bucket-name
|
||||
objref:
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
apiVersion: v1
|
||||
fieldref:
|
||||
fieldpath: data.bucketName
|
||||
- name: kfp-default-pipeline-root
|
||||
- fieldref:
|
||||
fieldPath: data.defaultPipelineRoot
|
||||
name: kfp-default-pipeline-root
|
||||
objref:
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
name: pipeline-install-config
|
||||
apiVersion: v1
|
||||
fieldref:
|
||||
fieldpath: data.defaultPipelineRoot
|
||||
configurations:
|
||||
- params.yaml
|
||||
- params.yaml
|
||||
|
||||
+2
-2
@@ -63,8 +63,8 @@ data:
|
||||
## cacheImage is the image that the mutating webhook will use to patch
|
||||
## cached steps with. Will be used to echo a message announcing that
|
||||
## the cached step result will be used. If not set it will default to
|
||||
## 'gcr.io/google-containers/busybox'
|
||||
cacheImage: "gcr.io/google-containers/busybox"
|
||||
## 'registry.k8s.io/busybox'
|
||||
cacheImage: "registry.k8s.io/busybox"
|
||||
## cacheNodeRestrictions the dummy container runing if output is cached
|
||||
## will run with the same affinity and node selector as the default pipeline
|
||||
## step. This is defaulted to 'false' to allow the pod to be scheduled on
|
||||
|
||||
+14
@@ -35,6 +35,20 @@ rules:
|
||||
- update
|
||||
- patch
|
||||
- delete
|
||||
- apiGroups:
|
||||
- kubeflow.org
|
||||
resources:
|
||||
- scheduledworkflows/finalizers
|
||||
verbs:
|
||||
- update
|
||||
- apiGroups:
|
||||
- pipelines.kubeflow.org
|
||||
resources:
|
||||
- pipelines
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
- apiGroups:
|
||||
- authorization.k8s.io
|
||||
resources:
|
||||
|
||||
+2
-2
@@ -4,6 +4,6 @@ resources:
|
||||
- cluster-role-binding.yaml
|
||||
- cluster-role.yaml
|
||||
configMapGenerator:
|
||||
- name: pipeline-api-server-config
|
||||
envs:
|
||||
- envs:
|
||||
- params.env
|
||||
name: pipeline-api-server-config
|
||||
|
||||
+4
-2
@@ -1,7 +1,9 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
commonLabels:
|
||||
app: cache-server
|
||||
resources:
|
||||
- cluster-role.yaml
|
||||
- cluster-role-binding.yaml
|
||||
labels:
|
||||
- includeSelectors: true
|
||||
pairs:
|
||||
app: cache-server
|
||||
|
||||
+14
-7
@@ -8,10 +8,21 @@ spec:
|
||||
matchLabels:
|
||||
app: ml-pipeline-ui
|
||||
rules:
|
||||
# Allow all requests from the ingress gateway
|
||||
- from:
|
||||
- source:
|
||||
namespaces:
|
||||
- istio-system
|
||||
principals:
|
||||
- cluster.local/ns/istio-system/sa/istio-ingressgateway-service-account
|
||||
|
||||
# Allow all requests with an `authorization` header but NOT a `kubeflow-userid` header.
|
||||
# This is needed to allow Kubernetes JWTs to be passed to the KFP API.
|
||||
- when:
|
||||
- key: request.headers[authorization]
|
||||
values:
|
||||
- "*"
|
||||
- key: request.headers[kubeflow-userid]
|
||||
notValues:
|
||||
- "*"
|
||||
---
|
||||
apiVersion: security.istio.io/v1beta1
|
||||
kind: AuthorizationPolicy
|
||||
@@ -32,11 +43,7 @@ spec:
|
||||
- cluster.local/ns/kubeflow/sa/ml-pipeline-scheduledworkflow
|
||||
- cluster.local/ns/kubeflow/sa/ml-pipeline-viewer-crd-service-account
|
||||
- cluster.local/ns/kubeflow/sa/kubeflow-pipelines-cache
|
||||
# allow access by any trusted principal
|
||||
- from:
|
||||
- source:
|
||||
requestPrincipals: ["*"]
|
||||
# For user workloads, which cannot user http headers for authentication
|
||||
# Allow all requests that dont have a `kubeflow-userid` header.
|
||||
- when:
|
||||
- key: request.headers[kubeflow-userid]
|
||||
notValues: ['*']
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
namespace: kubeflow
|
||||
commonLabels:
|
||||
app.kubernetes.io/name: kubeflow-pipelines
|
||||
app.kubernetes.io/component: ml-pipeline
|
||||
resources:
|
||||
- ../../pipeline/cluster-scoped
|
||||
- ../../cache-deployer/cluster-scoped
|
||||
@@ -31,3 +28,8 @@ patches:
|
||||
|
||||
configurations:
|
||||
- params.yaml
|
||||
labels:
|
||||
- includeSelectors: true
|
||||
pairs:
|
||||
app.kubernetes.io/component: ml-pipeline
|
||||
app.kubernetes.io/name: kubeflow-pipelines
|
||||
|
||||
+8
-8
@@ -1,16 +1,16 @@
|
||||
# Change resyncPeriodSeconds to 1 hour from insane 20 seconds
|
||||
# Only sync namespaces with pipelines.kubeflow.org/enabled = "true"
|
||||
apiVersion: metacontroller.k8s.io/v1alpha1
|
||||
kind: CompositeController
|
||||
kind: DecoratorController
|
||||
metadata:
|
||||
name: kubeflow-pipelines-profile-controller
|
||||
spec:
|
||||
generateSelector: true
|
||||
resyncPeriodSeconds: 3600
|
||||
parentResource:
|
||||
apiVersion: v1
|
||||
resources:
|
||||
- apiVersion: v1
|
||||
resource: namespaces
|
||||
childResources:
|
||||
labelSelector:
|
||||
matchLabels:
|
||||
pipelines.kubeflow.org/enabled: "true"
|
||||
attachments:
|
||||
- apiVersion: v1
|
||||
resource: secrets
|
||||
updateStrategy:
|
||||
@@ -38,4 +38,4 @@ spec:
|
||||
hooks:
|
||||
sync:
|
||||
webhook:
|
||||
url: http://kubeflow-pipelines-profile-controller/sync
|
||||
url: http://kubeflow-pipelines-profile-controller/sync
|
||||
+12
-2
@@ -6,12 +6,22 @@ spec:
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
annotations:
|
||||
labels:
|
||||
sidecar.istio.io/inject: "false"
|
||||
spec:
|
||||
containers:
|
||||
- name: profile-controller
|
||||
image: python:3.7
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
seccompProfile:
|
||||
type: RuntimeDefault
|
||||
runAsNonRoot: true
|
||||
runAsUser: 1000
|
||||
runAsGroup: 0
|
||||
capabilities:
|
||||
drop:
|
||||
- ALL
|
||||
image: public.ecr.aws/docker/library/python:3.12
|
||||
command: ["python", "/hooks/sync.py"]
|
||||
envFrom:
|
||||
- configMapRef:
|
||||
|
||||
+9
-7
@@ -1,16 +1,18 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
namespace: kubeflow
|
||||
commonLabels:
|
||||
app: kubeflow-pipelines-profile-controller
|
||||
resources:
|
||||
- service.yaml
|
||||
- deployment.yaml
|
||||
- composite-controller.yaml
|
||||
- decorator-controller.yaml
|
||||
configMapGenerator:
|
||||
- name: kubeflow-pipelines-profile-controller-code
|
||||
files:
|
||||
- files:
|
||||
- sync.py
|
||||
- name: kubeflow-pipelines-profile-controller-env
|
||||
envs:
|
||||
name: kubeflow-pipelines-profile-controller-code
|
||||
- envs:
|
||||
- params.env
|
||||
name: kubeflow-pipelines-profile-controller-env
|
||||
labels:
|
||||
- includeSelectors: true
|
||||
pairs:
|
||||
app: kubeflow-pipelines-profile-controller
|
||||
|
||||
+15
-16
@@ -36,9 +36,9 @@ def get_settings_from_env(controller_port=None,
|
||||
Settings are pulled from the all-caps version of the setting name. The
|
||||
following defaults are used if those environment variables are not set
|
||||
to enable backwards compatibility with previous versions of this script:
|
||||
visualization_server_image: gcr.io/ml-pipeline/visualization-server
|
||||
visualization_server_image: ghcr.io/kubeflow/kfp-visualization-server
|
||||
visualization_server_tag: value of KFP_VERSION environment variable
|
||||
frontend_image: gcr.io/ml-pipeline/frontend
|
||||
frontend_image: ghcr.io/kubeflow/kfp-frontend
|
||||
frontend_tag: value of KFP_VERSION environment variable
|
||||
disable_istio_sidecar: Required (no default)
|
||||
minio_access_key: Required (no default)
|
||||
@@ -51,11 +51,11 @@ def get_settings_from_env(controller_port=None,
|
||||
|
||||
settings["visualization_server_image"] = \
|
||||
visualization_server_image or \
|
||||
os.environ.get("VISUALIZATION_SERVER_IMAGE", "gcr.io/ml-pipeline/visualization-server")
|
||||
os.environ.get("VISUALIZATION_SERVER_IMAGE", "ghcr.io/kubeflow/kfp-visualization-server")
|
||||
|
||||
settings["frontend_image"] = \
|
||||
frontend_image or \
|
||||
os.environ.get("FRONTEND_IMAGE", "gcr.io/ml-pipeline/frontend")
|
||||
os.environ.get("FRONTEND_IMAGE", "ghcr.io/kubeflow/kfp-frontend")
|
||||
|
||||
# Look for specific tags for each image first, falling back to
|
||||
# previously used KFP_VERSION environment variable for backwards
|
||||
@@ -99,15 +99,14 @@ def server_factory(visualization_server_image,
|
||||
Returns an HTTPServer populated with Handler with customized settings
|
||||
"""
|
||||
class Controller(BaseHTTPRequestHandler):
|
||||
def sync(self, parent, children):
|
||||
def sync(self, parent, attachments):
|
||||
# parent is a namespace
|
||||
namespace = parent.get("metadata", {}).get("name")
|
||||
|
||||
pipeline_enabled = parent.get("metadata", {}).get(
|
||||
"labels", {}).get("pipelines.kubeflow.org/enabled")
|
||||
|
||||
if pipeline_enabled != "true":
|
||||
return {"status": {}, "children": []}
|
||||
return {"status": {}, "attachments": []}
|
||||
|
||||
desired_configmap_count = 1
|
||||
desired_resources = []
|
||||
@@ -129,16 +128,16 @@ def server_factory(visualization_server_image,
|
||||
# Compute status based on observed state.
|
||||
desired_status = {
|
||||
"kubeflow-pipelines-ready":
|
||||
len(children["Secret.v1"]) == 1 and
|
||||
len(children["ConfigMap.v1"]) == desired_configmap_count and
|
||||
len(children["Deployment.apps/v1"]) == 2 and
|
||||
len(children["Service.v1"]) == 2 and
|
||||
len(children["DestinationRule.networking.istio.io/v1alpha3"]) == 1 and
|
||||
len(children["AuthorizationPolicy.security.istio.io/v1beta1"]) == 1 and
|
||||
len(attachments["Secret.v1"]) == 1 and
|
||||
len(attachments["ConfigMap.v1"]) == desired_configmap_count and
|
||||
len(attachments["Deployment.apps/v1"]) == 2 and
|
||||
len(attachments["Service.v1"]) == 2 and
|
||||
len(attachments["DestinationRule.networking.istio.io/v1alpha3"]) == 1 and
|
||||
len(attachments["AuthorizationPolicy.security.istio.io/v1beta1"]) == 1 and
|
||||
"True" or "False"
|
||||
}
|
||||
|
||||
# Generate the desired child object(s).
|
||||
# Generate the desired attachment object(s).
|
||||
desired_resources += [
|
||||
{
|
||||
"apiVersion": "v1",
|
||||
@@ -376,13 +375,13 @@ def server_factory(visualization_server_image,
|
||||
},
|
||||
})
|
||||
|
||||
return {"status": desired_status, "children": desired_resources}
|
||||
return {"status": desired_status, "attachments": desired_resources}
|
||||
|
||||
def do_POST(self):
|
||||
# Serve the sync() function as a JSON webhook.
|
||||
observed = json.loads(
|
||||
self.rfile.read(int(self.headers.get("content-length"))))
|
||||
desired = self.sync(observed["parent"], observed["children"])
|
||||
desired = self.sync(observed["object"], observed["attachments"])
|
||||
|
||||
self.send_response(200)
|
||||
self.send_header("Content-type", "application/json")
|
||||
|
||||
+2
-2
@@ -49,8 +49,8 @@ DATA_CORRECT_CHILDREN = {
|
||||
DATA_MISSING_PIPELINE_ENABLED = {"parent": {}, "children": {}}
|
||||
|
||||
# Default values when environments are not explicit
|
||||
DEFAULT_FRONTEND_IMAGE = "gcr.io/ml-pipeline/frontend"
|
||||
DEFAULT_VISUALIZATION_IMAGE = "gcr.io/ml-pipeline/visualization-server"
|
||||
DEFAULT_FRONTEND_IMAGE = "ghcr.io/kubeflow/kfp-frontend"
|
||||
DEFAULT_VISUALIZATION_IMAGE = "ghcr.io/kubeflow/kfp-visualization-server"
|
||||
|
||||
# Variables used for environment variable sets
|
||||
VISUALIZATION_SERVER_IMAGE = "vis-image"
|
||||
|
||||
+4
-2
@@ -1,8 +1,10 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
namespace: kubeflow
|
||||
commonLabels:
|
||||
app: ml-pipeline-ui
|
||||
resources:
|
||||
- cluster-role.yaml
|
||||
- cluster-role-binding.yaml
|
||||
labels:
|
||||
- includeSelectors: true
|
||||
pairs:
|
||||
app: ml-pipeline-ui
|
||||
|
||||
+6
@@ -15,6 +15,12 @@ rules:
|
||||
- update
|
||||
- patch
|
||||
- delete
|
||||
- apiGroups:
|
||||
- pipelines.kubeflow.org
|
||||
resources:
|
||||
- runs
|
||||
verbs:
|
||||
- create
|
||||
- apiGroups:
|
||||
- kubeflow.org
|
||||
resources:
|
||||
|
||||
+1
@@ -97,6 +97,7 @@ rules:
|
||||
- workflows/finalizers
|
||||
- workfloweventbindings
|
||||
- workflowtemplates
|
||||
- workflowtaskresults
|
||||
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user