Skip to content

Commit

Permalink
🔧 Replace commonLabels with labels and selectors
Browse files Browse the repository at this point in the history
Used `kustomize edit fix  --vars`

Signed-off-by: etheleon <[email protected]>
  • Loading branch information
etheleon committed Oct 16, 2024
1 parent 1b5e378 commit 2b40df0
Show file tree
Hide file tree
Showing 19 changed files with 86 additions and 46 deletions.
6 changes: 4 additions & 2 deletions manifests/kustomize/base/cache-deployer/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@ resources:
- cache-deployer-role.yaml
- cache-deployer-rolebinding.yaml
- cache-deployer-deployment.yaml
commonLabels:
app: cache-deployer
images:
- name: gcr.io/ml-pipeline/cache-deployer
newTag: 2.3.0
labels:
- includeSelectors: true
pairs:
app: cache-deployer
6 changes: 4 additions & 2 deletions manifests/kustomize/base/cache/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ resources:
- cache-rolebinding.yaml
- cache-sa.yaml
- cache-service.yaml
commonLabels:
app: cache-server
images:
- name: gcr.io/ml-pipeline/cache-server
newTag: 2.3.0
labels:
- includeSelectors: true
pairs:
app: cache-server
Original file line number Diff line number Diff line change
@@ -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
Original file line number Diff line number Diff line change
@@ -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
Expand Down Expand Up @@ -31,3 +28,8 @@ patches:

configurations:
- params.yaml
labels:
- includeSelectors: true
pairs:
app.kubernetes.io/component: ml-pipeline
app.kubernetes.io/name: kubeflow-pipelines
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: kubeflow
commonLabels:
app: kubeflow-pipelines-profile-controller
resources:
- service.yaml
- deployment.yaml
Expand All @@ -13,4 +11,8 @@ configMapGenerator:
- sync.py
- name: kubeflow-pipelines-profile-controller-env
envs:
- params.env
- params.env
labels:
- includeSelectors: true
pairs:
app: kubeflow-pipelines-profile-controller
Original file line number Diff line number Diff line change
@@ -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 changes: 4 additions & 2 deletions manifests/kustomize/env/aws/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,7 @@ patches:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
6 changes: 4 additions & 2 deletions manifests/kustomize/env/azure/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,7 @@ secretGenerator:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
8 changes: 5 additions & 3 deletions manifests/kustomize/env/cert-manager/base/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: kubeflow
namespace: kubeflow

resources:
- cache-cert-issuer.yaml
- cache-cert.yaml
- cache-webhook-config.yaml
commonLabels:
app: cache-server-cert-manager

configurations:
- params.yaml
labels:
- includeSelectors: true
pairs:
app: cache-server-cert-manager
8 changes: 5 additions & 3 deletions manifests/kustomize/env/dev/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

resources:
# Application controller is used to provide Google Cloud Console integration.
resources:
- ../../third-party/application
- ../../base/application
- ../platform-agnostic
Expand All @@ -11,9 +11,11 @@ resources:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines

# !!! If you want to customize the namespace,
# please refer sample/cluster-scoped-resources to update the namespace for cluster-scoped-resources
namespace: kubeflow
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
8 changes: 5 additions & 3 deletions manifests/kustomize/env/dev/postgresql/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

resources:
# Application controller is used to provide Google Cloud Console integration.
resources:
- ../../../third-party/application
- ../../../base/application
- ../../platform-agnostic-postgresql
Expand All @@ -11,9 +11,11 @@ resources:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines

# !!! If you want to customize the namespace,
# please refer sample/cluster-scoped-resources to update the namespace for cluster-scoped-resources
namespace: kubeflow
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
8 changes: 5 additions & 3 deletions manifests/kustomize/env/gcp/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

resources:
# Application controller is used to provide Google Cloud Console integration.
resources:
- ../../third-party/application
- ../../base/application
- ../../base/installs/generic
Expand All @@ -15,8 +15,6 @@ resources:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines

# !!! If you want to customize the namespace,
# please also update base/cache-deployer/cluster-scoped/cache-deployer-clusterrolebinding.yaml
Expand All @@ -30,3 +28,7 @@ configMapGenerator:
- name: pipeline-install-config
env: params.env
behavior: merge
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
6 changes: 4 additions & 2 deletions manifests/kustomize/env/plain-multi-user/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,11 @@ resources:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines

# !!! If you want to customize the namespace,
# please also update base/cache-deployer/cluster-scoped/cache-deployer-clusterrolebinding.yaml
namespace: kubeflow
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@ resources:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines

# !!! If you want to customize the namespace,
# please also update base/cache-deployer/cluster-scoped/cache-deployer-clusterrolebinding.yaml
namespace: kubeflow
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@ resources:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines

# !!! If you want to customize the namespace,
# please also update base/cache-deployer/cluster-scoped/cache-deployer-clusterrolebinding.yaml
namespace: kubeflow
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ resources:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines

patches:
- path: tekton-config.yaml
Expand Down Expand Up @@ -65,4 +63,8 @@ patches:
- name: ml-pipeline-ui
env:
- name: POD_LOG_CONTAINER_NAME
value: step-user-main
value: step-user-main
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines
8 changes: 6 additions & 2 deletions manifests/kustomize/sample/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ resources:
# Identifier for application manager to apply ownerReference.
# The ownerReference ensures the resources get garbage collected
# when application is deleted.
commonLabels:
application-crd-id: kubeflow-pipelines

# Used by Kustomize
configMapGenerator:
Expand All @@ -36,3 +34,9 @@ namespace: kubeflow
# 2. Change values in params-db-secret.env file for CloudSQL username and password
# 3. kustomize build ./ | kubectl apply -f -
####
labels:
- includeSelectors: true
pairs:
application-crd-id: kubeflow-pipelines


Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
commonLabels:
"app.kubernetes.io/part-of": "dex"
resources:
- dex-cm.yaml
- dex-role.yaml
- dex-sa.yaml
- dex-rb.yaml
- dex-deploy.yaml
- dev-svc.yaml
labels:
- includeSelectors: true
pairs:
app.kubernetes.io/part-of: dex
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@ resources:
- crd.yaml
- service-account.yaml
- stateful-set.yaml
commonLabels:
kustomize.component: metacontroller
labels:
- includeSelectors: true
pairs:
kustomize.component: metacontroller

# Update metacontroller CRD:
# Copy the upstream file to crd.yaml in this folder.
# Upstream file: https://github.com/metacontroller/metacontroller/blob/master/manifests/production/metacontroller-crds-v1.yaml
# Upstream file: https://github.com/metacontroller/metacontroller/blob/master/manifests/production/metacontroller-crds-v1.yaml

0 comments on commit 2b40df0

Please sign in to comment.