diff --git a/Tiltfile b/Tiltfile index 7aa07e811..5682e106c 100644 --- a/Tiltfile +++ b/Tiltfile @@ -2,7 +2,7 @@ load('.tilt-support', 'deploy_repo') operator_controller = { 'image': 'quay.io/operator-framework/operator-controller', - 'yaml': 'config/overlays/cert-manager', + 'yaml': 'config/overlays/tilt-local-dev', 'binaries': { './cmd/operator-controller': 'operator-controller-controller-manager', }, diff --git a/config/overlays/tilt-local-dev/kustomization.yaml b/config/overlays/tilt-local-dev/kustomization.yaml new file mode 100644 index 000000000..81bc3ffdc --- /dev/null +++ b/config/overlays/tilt-local-dev/kustomization.yaml @@ -0,0 +1,16 @@ +# kustomization file for secure operator-controller +# DO NOT ADD A NAMESPACE HERE +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +resources: +- ../../base +components: +- ../../components/tls +# ca must be last or tls will overwrite the namespaces +- ../../components/ca + +patches: + - target: + kind: Deployment + name: controller-manager + path: patches/dev-deployment.yaml diff --git a/config/overlays/tilt-local-dev/patches/dev-deployment.yaml b/config/overlays/tilt-local-dev/patches/dev-deployment.yaml new file mode 100644 index 000000000..2d7cb9467 --- /dev/null +++ b/config/overlays/tilt-local-dev/patches/dev-deployment.yaml @@ -0,0 +1,13 @@ +# remove livenessProbe and readinessProbe so container doesn't restart during breakpoints +- op: replace + path: /spec/template/spec/containers/0/livenessProbe + value: null +- op: replace + path: /spec/template/spec/containers/0/readinessProbe + value: null +- op: remove + # remove --leader-elect so container doesn't restart during breakpoints + path: /spec/template/spec/containers/0/args/2 +- op: add + path: /spec/template/spec/containers/0/args/- + value: --feature-gates=PreflightPermissions=true