diff options
author | Julien Dessaux | 2021-03-11 18:53:14 +0100 |
---|---|---|
committer | Julien Dessaux | 2021-03-11 18:53:14 +0100 |
commit | 60d3abc6ecdc21b4ab921d34a55b4af48690f55a (patch) | |
tree | 1ee530dd7367d743fb619f341100e41df22e1985 /content/blog/kubernetes/get_key_and_certificae.md | |
parent | Updated docsy theme (diff) | |
download | www-60d3abc6ecdc21b4ab921d34a55b4af48690f55a.tar.gz www-60d3abc6ecdc21b4ab921d34a55b4af48690f55a.tar.bz2 www-60d3abc6ecdc21b4ab921d34a55b4af48690f55a.zip |
Rewrote the whole website to get rid on a heavy theme
Diffstat (limited to 'content/blog/kubernetes/get_key_and_certificae.md')
-rw-r--r-- | content/blog/kubernetes/get_key_and_certificae.md | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/content/blog/kubernetes/get_key_and_certificae.md b/content/blog/kubernetes/get_key_and_certificae.md new file mode 100644 index 0000000..c66cac8 --- /dev/null +++ b/content/blog/kubernetes/get_key_and_certificae.md @@ -0,0 +1,10 @@ +--- +title: "Get tls certificate and key from a kubernetes secret" +date: 2020-08-06 +--- + +My use case is to deploy a wildcard certificate that was previously handled by an acme.sh on my legacy lxd containers. Since moving to kubernetes parts of my services I have been using cert-manager to issue letsencrypt certificates. Since I am not done yet I looked into a way of getting a certificate out of kubernetes. Assuming we are working with a secret named `wild.adyxax.org-cert` and our namespace is named `legacy` : +{{< highlight sh >}} +kubectl -n legacy get secret wild.adyxax.org-cert -o json -o=jsonpath="{.data.tls\.crt}" | base64 -d > fullchain.cer +kubectl -n legacy get secret wild.adyxax.org-cert -o json -o=jsonpath="{.data.tls\.key}" | base64 -d > adyxax.org.key +{{< /highlight >}} |