From 66fc5298fd645b5be1e06c2057d07418c28c87ed Mon Sep 17 00:00:00 2001 From: James Rissler Date: Fri, 18 Dec 2020 18:06:57 -0600 Subject: [PATCH 1/2] Update to apps/v1 --- deploy/cert-manager-webhook-godaddy/templates/deployment.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/deploy/cert-manager-webhook-godaddy/templates/deployment.yaml b/deploy/cert-manager-webhook-godaddy/templates/deployment.yaml index 2668251..9248b8a 100644 --- a/deploy/cert-manager-webhook-godaddy/templates/deployment.yaml +++ b/deploy/cert-manager-webhook-godaddy/templates/deployment.yaml @@ -1,5 +1,5 @@ -apiVersion: apps/v1beta2 -kind: Deployment +apiVersion: apps/v1 +kind: Deployment metadata: name: {{ include "godaddy-webhook.fullname" . }} labels: From 65fcb1db3ff1accdc920766e9f6038b0f8830090 Mon Sep 17 00:00:00 2001 From: James Rissler Date: Sat, 19 Dec 2020 08:19:02 -0600 Subject: [PATCH 2/2] Update to work for kubernetes 1.16 --- README.md | 2 +- deploy/cert-manager-webhook-godaddy/Chart.yaml | 2 +- .../templates/rbac.yaml | 16 ++++++++-------- .../repo/cert-manager-webhook-godaddy-0.1.6.tgz | Bin 0 -> 2736 bytes deploy/repo/index.yaml | 13 +++++++++++-- main_test.go | 16 ++++++++-------- 6 files changed, 29 insertions(+), 20 deletions(-) create mode 100644 deploy/repo/cert-manager-webhook-godaddy-0.1.6.tgz diff --git a/README.md b/README.md index 0606a74..1099043 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ spec: webhook: groupName: acme.blackhouse.dev solverName: godaddy - config: + config: authAPIKey: authAPISecretRef: name: godaddy-api-key diff --git a/deploy/cert-manager-webhook-godaddy/Chart.yaml b/deploy/cert-manager-webhook-godaddy/Chart.yaml index 553efaa..81d84d2 100644 --- a/deploy/cert-manager-webhook-godaddy/Chart.yaml +++ b/deploy/cert-manager-webhook-godaddy/Chart.yaml @@ -2,4 +2,4 @@ apiVersion: v2 appVersion: 0.0.1 description: A GoDaddy webhook for cert-manager name: cert-manager-webhook-godaddy -version: 0.1.5 +version: 0.1.6 diff --git a/deploy/cert-manager-webhook-godaddy/templates/rbac.yaml b/deploy/cert-manager-webhook-godaddy/templates/rbac.yaml index 2a256c5..0ba7ae6 100644 --- a/deploy/cert-manager-webhook-godaddy/templates/rbac.yaml +++ b/deploy/cert-manager-webhook-godaddy/templates/rbac.yaml @@ -11,10 +11,10 @@ metadata: # Grant the webhook permission to read the ConfigMap containing the Kubernetes # apiserver's requestheader-ca-certificate. # This ConfigMap is automatically created by the Kubernetes apiserver. -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: - name: {{ include "godaddy-webhook.fullname" . }}:webhook-authentication-reader + name: {{ include "godaddy-webhook.fullname" . }}-webhook-authentication-reader namespace: kube-system labels: app: {{ include "godaddy-webhook.name" . }} @@ -33,10 +33,10 @@ subjects: --- # apiserver gets the auth-delegator role to delegate auth decisions to # the core apiserver -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding metadata: - name: {{ include "godaddy-webhook.fullname" . }}:auth-delegator + name: {{ include "godaddy-webhook.fullname" . }}-auth-delegator labels: app: {{ include "godaddy-webhook.name" . }} chart: {{ include "godaddy-webhook.chart" . }} @@ -53,10 +53,10 @@ subjects: namespace: {{ .Release.Namespace }} --- # Grant cert-manager permission to validate using our apiserver -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole metadata: - name: {{ include "godaddy-webhook.fullname" . }}:domain-solver + name: {{ include "godaddy-webhook.fullname" . }}-domain-solver labels: app: {{ include "godaddy-webhook.name" . }} chart: {{ include "godaddy-webhook.chart" . }} @@ -70,10 +70,10 @@ rules: verbs: - 'create' --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding metadata: - name: {{ include "godaddy-webhook.fullname" . }}:domain-solver + name: {{ include "godaddy-webhook.fullname" . }}-domain-solver labels: app: {{ include "godaddy-webhook.name" . }} chart: {{ include "godaddy-webhook.chart" . }} diff --git a/deploy/repo/cert-manager-webhook-godaddy-0.1.6.tgz b/deploy/repo/cert-manager-webhook-godaddy-0.1.6.tgz new file mode 100644 index 0000000000000000000000000000000000000000..4c470d3f0419a5a065ed4fe9110098c1de43be43 GIT binary patch literal 2736 zcmV;h3QzSPiwG0|00000|0w_~VMtOiV@ORlOnEsqVl!4SWK%V1T2nbTPgYhoO;>Dc zVQyr3R8em|NM&qo0PGuoZ`-)Ff9q4cIXm<&JIQk5B!z(cBTKuk*xDLR*I^ijf|i~o zUMNyWQf_@|_SpxLk}b)xV<&C0A|}vOkx0JB_xlGEqtt#*I7w0ZpKzQBap9*TAxSdp zpJhbqU`BHGf@ANYN${x0TK%6AR-(GI0k}#3kA_Db{XYqhPj>o$A0w5bEZ$h1 zC2@|yn34D*6Q#l+!KvpN`FQQbBk}-@cB_KK9ToQg6v`=$@idM_$@QBhE8uxFCn=gu zBo;zZE#xeM-%2tIsOWPPDRP{W{#w%kph;SrCV--3Y$O+J+A;Agd2)#;(YM~0u znjZLzS)^nd0+(YLe*wV<7jHDpG<*RqOCH1Vp?#$Jc{!QT&(QN1n;}o^v%~XDBGCwB z4#SxKnejA?PADcoio%{C@cxNzcRODj80Itz#u$@QAt;d}{H+|L6u#W^hbM)=$Fm8+rV>95w}b5&XLP4 zp5xkjyETG^q+Cy+_k;3(P`%D>4(>Mcw(7YhhYbcB^{J8{!(7YcN@CnBM#jiCV6>gx zTY0P|)!lQI)WH`Md@&Lu^#0U?-pAgy`n4J-g=}(8Q;x|irAn0b@+Nj>j-n~=!H<;3 ztW4GlaqtstgMbu5pPjA-9+Phf_6((_6KX8UJ;Ju(D^G6#Ub}V8)Ge`iXfL%J-)d|a z|B-@LsnRW~0XM{dgTcu`H~u@>#sBv+n)N?YP>Cs3+9k5V#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I2j5OUyu~l zyf~%G!WutN88QYb6JvMrk@ECsV{3?}Q?&P?8t(~DyglG1do-EYkA=hu{fvpb8S{sq z0(i^W3ro6w{XiVaZvao;ts=WO`eJZ^DU`#H&{Xpl1xBp*n4?Yk{MXBJ`^B2ks q3Mouf>jgAH(s%Qu`1PULxf{E&8@sXb_+J130RR8Au%rV3OaK6+X>e}< literal 0 HcmV?d00001 diff --git a/deploy/repo/index.yaml b/deploy/repo/index.yaml index db97880..cdbdb7b 100644 --- a/deploy/repo/index.yaml +++ b/deploy/repo/index.yaml @@ -3,11 +3,20 @@ entries: cert-manager-webhook-godaddy: - apiVersion: v2 appVersion: 0.0.1 - created: "2019-12-18T21:21:46.189128+13:00" + created: "2020-12-19T08:03:10.735469-06:00" + description: A GoDaddy webhook for cert-manager + digest: f033ee4d3abedc2017fc22d755a16b07052597fec27eab39fb97f31a43660f03 + name: cert-manager-webhook-godaddy + urls: + - cert-manager-webhook-godaddy-0.1.6.tgz + version: 0.1.6 + - apiVersion: v2 + appVersion: 0.0.1 + created: "2020-12-19T08:03:10.735029-06:00" description: A GoDaddy webhook for cert-manager digest: 476535bbe4871f343fca48efb2b492b0f795a502e1a72354bccdd81d9b4aaf43 name: cert-manager-webhook-godaddy urls: - cert-manager-webhook-godaddy-0.1.5.tgz version: 0.1.5 -generated: "2019-12-18T21:21:46.1881291+13:00" +generated: "2020-12-19T08:03:10.733657-06:00" diff --git a/main_test.go b/main_test.go index 3f02d0d..c32dbcc 100644 --- a/main_test.go +++ b/main_test.go @@ -7,7 +7,7 @@ import ( "fmt" "github.com/jetstack/cert-manager/test/acme/dns" - + "k8s.io/client-go/rest" ) @@ -29,14 +29,14 @@ func (c *testCustomDNSProviderSolver) Initialize(kubeClientConfig *rest.Config, } cmd := exec.Command( - fmt.Sprintf("%s/kubectl", kubeBuilderBinPath), - "apply", - "-f", - fmt.Sprintf("%s/api-key.yaml", testPath), - "-s", + fmt.Sprintf("%s/kubectl", kubeBuilderBinPath), + "apply", + "-f", + fmt.Sprintf("%s/api-key.yaml", testPath), + "-s", kubeClientConfig.Host, ) - + _, err = cmd.Output() return err @@ -55,5 +55,5 @@ func TestRunsSuite(t *testing.T) { ) fixture.RunConformance(t) - + }