mirror of
https://github.com/actions/actions-runner-controller.git
synced 2025-12-10 11:41:27 +00:00
* fix(chart): add namespace selector to webhooks when in singleNamespace mode * docs: expand multi controller setup Co-authored-by: Callum Tait <15716903+toast-gear@users.noreply.github.com>
222 lines
6.3 KiB
YAML
222 lines
6.3 KiB
YAML
|
|
---
|
|
apiVersion: admissionregistration.k8s.io/v1
|
|
kind: MutatingWebhookConfiguration
|
|
metadata:
|
|
creationTimestamp: null
|
|
name: {{ include "actions-runner-controller.fullname" . }}-mutating-webhook-configuration
|
|
{{- if .Values.certManagerEnabled }}
|
|
annotations:
|
|
cert-manager.io/inject-ca-from: {{ .Release.Namespace }}/{{ include "actions-runner-controller.servingCertName" . }}
|
|
{{- end }}
|
|
webhooks:
|
|
- admissionReviewVersions:
|
|
- v1beta1
|
|
{{- if .Values.scope.singleNamespace }}
|
|
namespaceSelector:
|
|
matchLabels:
|
|
name: {{ default .Release.Namespace .Values.scope.watchNamespace }}
|
|
{{- end }}
|
|
clientConfig:
|
|
{{- if .Values.admissionWebHooks.caBundle }}
|
|
caBundle: {{ quote .Values.admissionWebHooks.caBundle }}
|
|
{{- end }}
|
|
service:
|
|
name: {{ include "actions-runner-controller.webhookServiceName" . }}
|
|
namespace: {{ .Release.Namespace }}
|
|
path: /mutate-actions-summerwind-dev-v1alpha1-runner
|
|
failurePolicy: Fail
|
|
name: mutate.runner.actions.summerwind.dev
|
|
rules:
|
|
- apiGroups:
|
|
- actions.summerwind.dev
|
|
apiVersions:
|
|
- v1alpha1
|
|
operations:
|
|
- CREATE
|
|
- UPDATE
|
|
resources:
|
|
- runners
|
|
sideEffects: None
|
|
- admissionReviewVersions:
|
|
- v1beta1
|
|
{{- if .Values.scope.singleNamespace }}
|
|
namespaceSelector:
|
|
matchLabels:
|
|
name: {{ default .Release.Namespace .Values.scope.watchNamespace }}
|
|
{{- end }}
|
|
clientConfig:
|
|
{{- if .Values.admissionWebHooks.caBundle }}
|
|
caBundle: {{ .Values.admissionWebHooks.caBundle }}
|
|
{{- end }}
|
|
service:
|
|
name: {{ include "actions-runner-controller.webhookServiceName" . }}
|
|
namespace: {{ .Release.Namespace }}
|
|
path: /mutate-actions-summerwind-dev-v1alpha1-runnerdeployment
|
|
failurePolicy: Fail
|
|
name: mutate.runnerdeployment.actions.summerwind.dev
|
|
rules:
|
|
- apiGroups:
|
|
- actions.summerwind.dev
|
|
apiVersions:
|
|
- v1alpha1
|
|
operations:
|
|
- CREATE
|
|
- UPDATE
|
|
resources:
|
|
- runnerdeployments
|
|
sideEffects: None
|
|
- admissionReviewVersions:
|
|
- v1beta1
|
|
{{- if .Values.scope.singleNamespace }}
|
|
namespaceSelector:
|
|
matchLabels:
|
|
name: {{ default .Release.Namespace .Values.scope.watchNamespace }}
|
|
{{- end }}
|
|
clientConfig:
|
|
{{- if .Values.admissionWebHooks.caBundle }}
|
|
caBundle: {{ .Values.admissionWebHooks.caBundle }}
|
|
{{- end }}
|
|
service:
|
|
name: {{ include "actions-runner-controller.webhookServiceName" . }}
|
|
namespace: {{ .Release.Namespace }}
|
|
path: /mutate-actions-summerwind-dev-v1alpha1-runnerreplicaset
|
|
failurePolicy: Fail
|
|
name: mutate.runnerreplicaset.actions.summerwind.dev
|
|
rules:
|
|
- apiGroups:
|
|
- actions.summerwind.dev
|
|
apiVersions:
|
|
- v1alpha1
|
|
operations:
|
|
- CREATE
|
|
- UPDATE
|
|
resources:
|
|
- runnerreplicasets
|
|
sideEffects: None
|
|
- admissionReviewVersions:
|
|
- v1beta1
|
|
{{- if .Values.scope.singleNamespace }}
|
|
namespaceSelector:
|
|
matchLabels:
|
|
name: {{ default .Release.Namespace .Values.scope.watchNamespace }}
|
|
{{- end }}
|
|
clientConfig:
|
|
{{- if .Values.admissionWebHooks.caBundle }}
|
|
caBundle: {{ .Values.admissionWebHooks.caBundle }}
|
|
{{- end }}
|
|
service:
|
|
name: {{ include "actions-runner-controller.webhookServiceName" . }}
|
|
namespace: {{ .Release.Namespace }}
|
|
path: /mutate-runner-set-pod
|
|
failurePolicy: Fail
|
|
name: mutate-runner-pod.webhook.actions.summerwind.dev
|
|
rules:
|
|
- apiGroups:
|
|
- ""
|
|
apiVersions:
|
|
- v1
|
|
operations:
|
|
- CREATE
|
|
resources:
|
|
- pods
|
|
sideEffects: None
|
|
objectSelector:
|
|
matchLabels:
|
|
"actions-runner-controller/inject-registration-token": "true"
|
|
---
|
|
apiVersion: admissionregistration.k8s.io/v1
|
|
kind: ValidatingWebhookConfiguration
|
|
metadata:
|
|
creationTimestamp: null
|
|
name: {{ include "actions-runner-controller.fullname" . }}-validating-webhook-configuration
|
|
{{- if .Values.certManagerEnabled }}
|
|
annotations:
|
|
cert-manager.io/inject-ca-from: {{ .Release.Namespace }}/{{ include "actions-runner-controller.servingCertName" . }}
|
|
{{- end }}
|
|
webhooks:
|
|
- admissionReviewVersions:
|
|
- v1beta1
|
|
{{- if .Values.scope.singleNamespace }}
|
|
namespaceSelector:
|
|
matchLabels:
|
|
name: {{ default .Release.Namespace .Values.scope.watchNamespace }}
|
|
{{- end }}
|
|
clientConfig:
|
|
{{- if .Values.admissionWebHooks.caBundle }}
|
|
caBundle: {{ .Values.admissionWebHooks.caBundle }}
|
|
{{- end }}
|
|
service:
|
|
name: {{ include "actions-runner-controller.webhookServiceName" . }}
|
|
namespace: {{ .Release.Namespace }}
|
|
path: /validate-actions-summerwind-dev-v1alpha1-runner
|
|
failurePolicy: Fail
|
|
name: validate.runner.actions.summerwind.dev
|
|
rules:
|
|
- apiGroups:
|
|
- actions.summerwind.dev
|
|
apiVersions:
|
|
- v1alpha1
|
|
operations:
|
|
- CREATE
|
|
- UPDATE
|
|
resources:
|
|
- runners
|
|
sideEffects: None
|
|
- admissionReviewVersions:
|
|
- v1beta1
|
|
{{- if .Values.scope.singleNamespace }}
|
|
namespaceSelector:
|
|
matchLabels:
|
|
name: {{ default .Release.Namespace .Values.scope.watchNamespace }}
|
|
{{- end }}
|
|
clientConfig:
|
|
{{- if .Values.admissionWebHooks.caBundle }}
|
|
caBundle: {{ .Values.admissionWebHooks.caBundle }}
|
|
{{- end }}
|
|
service:
|
|
name: {{ include "actions-runner-controller.webhookServiceName" . }}
|
|
namespace: {{ .Release.Namespace }}
|
|
path: /validate-actions-summerwind-dev-v1alpha1-runnerdeployment
|
|
failurePolicy: Fail
|
|
name: validate.runnerdeployment.actions.summerwind.dev
|
|
rules:
|
|
- apiGroups:
|
|
- actions.summerwind.dev
|
|
apiVersions:
|
|
- v1alpha1
|
|
operations:
|
|
- CREATE
|
|
- UPDATE
|
|
resources:
|
|
- runnerdeployments
|
|
sideEffects: None
|
|
- admissionReviewVersions:
|
|
- v1beta1
|
|
{{- if .Values.scope.singleNamespace }}
|
|
namespaceSelector:
|
|
matchLabels:
|
|
name: {{ default .Release.Namespace .Values.scope.watchNamespace }}
|
|
{{- end }}
|
|
clientConfig:
|
|
{{- if .Values.admissionWebHooks.caBundle }}
|
|
caBundle: {{ .Values.admissionWebHooks.caBundle }}
|
|
{{- end }}
|
|
service:
|
|
name: {{ include "actions-runner-controller.webhookServiceName" . }}
|
|
namespace: {{ .Release.Namespace }}
|
|
path: /validate-actions-summerwind-dev-v1alpha1-runnerreplicaset
|
|
failurePolicy: Fail
|
|
name: validate.runnerreplicaset.actions.summerwind.dev
|
|
rules:
|
|
- apiGroups:
|
|
- actions.summerwind.dev
|
|
apiVersions:
|
|
- v1alpha1
|
|
operations:
|
|
- CREATE
|
|
- UPDATE
|
|
resources:
|
|
- runnerreplicasets
|
|
sideEffects: None
|