diff options
| author | Jesper Jensen <jesper@jnsn.dev> | 2026-11-01 20:33:36 +0100 |
|---|---|---|
| committer | Jesper Jensen <jesper@jnsn.dev> | 2026-11-01 21:34:19 +0100 |
| commit | a265ee04af9b21379c4f33cf8838e579f71d99d6 (patch) | |
| tree | 8511a085e413d813f660b0a4efa122959b27b93e /deploy/example-webhook | |
| parent | f4475b5f9e2e5e0cbf86e756c0e6a1bebcf1efdd (diff) | |
| download | cert-manager-webhook-hostinger-a265ee04af9b21379c4f33cf8838e579f71d99d6.tar.gz cert-manager-webhook-hostinger-a265ee04af9b21379c4f33cf8838e579f71d99d6.zip | |
Implement Hostinger DNS webhook
Diffstat (limited to 'deploy/example-webhook')
| -rw-r--r-- | deploy/example-webhook/Chart.yaml | 4 | ||||
| -rw-r--r-- | deploy/example-webhook/templates/rbac.yaml | 26 | ||||
| -rw-r--r-- | deploy/example-webhook/values.yaml | 5 |
3 files changed, 32 insertions, 3 deletions
diff --git a/deploy/example-webhook/Chart.yaml b/deploy/example-webhook/Chart.yaml index 77c6ead..fc4e447 100644 --- a/deploy/example-webhook/Chart.yaml +++ b/deploy/example-webhook/Chart.yaml @@ -1,5 +1,5 @@ apiVersion: v1 appVersion: "1.0" -description: A Helm chart for Kubernetes -name: example-webhook +description: cert-manager dns01 webhook for hostinger +name: cert-manager-webhook-hostinger version: 0.1.0 diff --git a/deploy/example-webhook/templates/rbac.yaml b/deploy/example-webhook/templates/rbac.yaml index 605fcf5..f952fd1 100644 --- a/deploy/example-webhook/templates/rbac.yaml +++ b/deploy/example-webhook/templates/rbac.yaml @@ -89,3 +89,29 @@ subjects: kind: ServiceAccount name: {{ .Values.certManager.serviceAccountName }} namespace: {{ .Values.certManager.namespace }} +--- +# Allow reading only the configured Hostinger token Secret. +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: {{ include "example-webhook.fullname" . }}:hostinger-token + namespace: {{ .Values.certManager.namespace }} +rules: + - apiGroups: [""] + resources: ["secrets"] + resourceNames: [{{ .Values.apiKeySecretName | quote }}] + verbs: ["get"] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: {{ include "example-webhook.fullname" . }}:hostinger-token + namespace: {{ .Values.certManager.namespace }} +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: {{ include "example-webhook.fullname" . }}:hostinger-token +subjects: + - kind: ServiceAccount + name: {{ include "example-webhook.fullname" . }} + namespace: {{ .Release.Namespace }} diff --git a/deploy/example-webhook/values.yaml b/deploy/example-webhook/values.yaml index 9423bd4..4826719 100644 --- a/deploy/example-webhook/values.yaml +++ b/deploy/example-webhook/values.yaml @@ -8,12 +8,15 @@ # The name will need to be referenced in each Issuer's `webhook` stanza to # inform cert-manager of where to send ChallengePayload resources in order to # solve the DNS01 challenge. -groupName: acme.mycompany.com +groupName: cert-manager-webhook-hostinger.jnsn.dev certManager: namespace: cert-manager serviceAccountName: cert-manager +# Token Secret in certManager.namespace; must match config.apiKeySecretRef.name. +apiKeySecretName: hostinger-api-token + image: repository: mycompany/webhook-image tag: latest |
