fix new k3s issuer convention
This commit is contained in:
parent
261303b08e
commit
50bcf23ee6
3 changed files with 5 additions and 5 deletions
|
@ -30,7 +30,7 @@
|
|||
|
||||
(defn generate-certificate [config]
|
||||
(let [{:keys [fqdn issuer]} config
|
||||
letsencrypt-issuer (str "letsencrypt-" (name issuer) "-issuer")]
|
||||
letsencrypt-issuer (name issuer)]
|
||||
(->
|
||||
(yaml/from-string (yaml/load-resource "jira/certificate.yaml"))
|
||||
(assoc-in [:spec :commonName] fqdn)
|
||||
|
@ -45,7 +45,7 @@
|
|||
(defn generate-ingress [config]
|
||||
(let [{:keys [fqdn issuer]
|
||||
:or {issuer :staging}} config
|
||||
letsencrypt-issuer (str "letsencrypt-" (name issuer) "-issuer")]
|
||||
letsencrypt-issuer (name issuer)]
|
||||
(->
|
||||
(yaml/from-string (yaml/load-resource "jira/ingress.yaml"))
|
||||
(assoc-in [:metadata :annotations :cert-manager.io/cluster-issuer] letsencrypt-issuer)
|
||||
|
|
|
@ -9,5 +9,5 @@ spec:
|
|||
dnsNames:
|
||||
- fqdn
|
||||
issuerRef:
|
||||
name: letsencrypt-staging-issuer
|
||||
name: staging
|
||||
kind: ClusterIssuer
|
|
@ -13,7 +13,7 @@
|
|||
:commonName "xx"
|
||||
:dnsNames ["xx"]
|
||||
:issuerRef
|
||||
{:name "letsencrypt-prod-issuer", :kind "ClusterIssuer"}}}
|
||||
{:name "prod", :kind "ClusterIssuer"}}}
|
||||
(cut/generate-certificate {:fqdn "xx" :issuer :prod}))))
|
||||
|
||||
(deftest should-generate-pvc
|
||||
|
@ -33,7 +33,7 @@
|
|||
{:name "ingress-jira"
|
||||
:annotations
|
||||
{:cert-manager.io/cluster-issuer
|
||||
"letsencrypt-staging-issuer"
|
||||
"staging"
|
||||
:nginx.ingress.kubernetes.io/proxy-body-size "256m"
|
||||
:nginx.ingress.kubernetes.io/ssl-redirect "true"
|
||||
:nginx.ingress.kubernetes.io/rewrite-target "/"
|
||||
|
|
Reference in a new issue