Skip to content

Commit e0499d3

Browse files
authored
replaced kubeapply jetstack cert-manager approach with helm install (coder#899)
1 parent 3b7116c commit e0499d3

File tree

5 files changed

+73
-33
lines changed

5 files changed

+73
-33
lines changed

changelog/1.28.0.md

+1-2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@ description: "Released on 02/16/2022"
1111
<!-- Turn off linting to avoid changing the link -->
1212
<!-- markdownlint-disable MD044 -->
1313

14-
[version support policy]:
15-
../setup/kubernetes#supported-kubernetes-versions
14+
[version support policy]: ../setup/kubernetes#supported-kubernetes-versions
1615

1716
<!-- markdownlint-enable MD044 -->
1817

guides/tls-certificates/azureDNS.md

+11-8
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ authority.
1414
> differently from earlier versions of Coder. Ensure that you're reading the
1515
> docs applicable to your Coder version.
1616
17-
This guide will show you how to install cert-manager v1.4.0 and set up your
18-
cluster to issue Let's Encrypt certificates for your Coder installation so that
19-
you can enable HTTPS on your Coder deployment. It will also show you how to
20-
configure your Coder hostname and dev URLs.
17+
This guide will show you how to install cert-manager and set up your cluster to
18+
issue Let's Encrypt certificates for your Coder installation so that you can
19+
enable HTTPS on your Coder deployment. It will also show you how to configure
20+
your Coder hostname and dev URLs.
2121

2222
There are three available methods to configuring the Azure DNS DNS01 Challenge
2323
via cert-manager:
@@ -84,7 +84,7 @@ the domain you're using for your Coder deployment.
8484
cert-manager:
8585

8686
```console
87-
kubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.4.0/cert-manager.yaml
87+
kubectl apply -f https://github.com/cert-manager/cert-manager/releases/download/v1.7.1/cert-manager.yaml
8888
```
8989

9090
1. Check that cert-manager installs correctly by running
@@ -300,11 +300,14 @@ However, to use all of the functionality you set up in this tutorial, use the
300300
following command instead:
301301

302302
```console
303+
# be sure to update the `stringValue` placeholder with the
304+
# proper value for your devurlsHostSecretName and hostSecretName
305+
303306
helm upgrade --install coder coder/coder --namespace coder \
304307
--version=<CODER_VERSION> \
305-
--set coderd.devurlsHost="coder.example.com" \
306-
--set coderd.tls.devurlsHostSecretName="coder-certs" \
307-
--set coderd.tls.hostSecretName="coder-certs" \
308+
--set coderd.devurlsHost="*.coder.example.com" \
309+
--set coderd.tls.devurlsHostSecretName="coder-certs-stringValue" \
310+
--set coderd.tls.hostSecretName="coder-certs-stringValue" \
308311
--wait
309312
```
310313

guides/tls-certificates/cloudDNS.md

+42-9
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ authority.
1414
> differently from earlier versions of Coder. Ensure that you're reading the
1515
> docs applicable to your Coder version.
1616
17-
This guide will show you how to install cert-manager v1.4.0 and set up your
18-
cluster to issue Let's Encrypt certificates for your Coder installation so that
19-
you can enable HTTPS on your Coder deployment. It will also show you how to
20-
configure your Coder hostname and dev URLs.
17+
This guide will show you how to install cert-manager and set up your cluster to
18+
issue Let's Encrypt certificates for your Coder installation so that you can
19+
enable HTTPS on your Coder deployment. It will also show you how to configure
20+
your Coder hostname and dev URLs.
2121

2222
> We recommend reviewing the official cert-manager
2323
> [documentation](https://cert-manager.io/docs/) if you encounter any issues or
@@ -36,14 +36,44 @@ You must have:
3636

3737
## Step 1: Add cert-manager to your Kubernetes cluster
3838

39-
To add cert-manager to your cluster, run:
39+
There are two ways to add cert-manager to your Kubernetes cluster.
40+
41+
## Option 1: `kubectl apply`
42+
43+
Add cert-manager to your cluster
44+
[using `kubectl apply`](https://cert-manager.io/docs/installation/kubectl/) by
45+
running:
4046

4147
```console
4248
kubectl apply -f https://github.com/cert-manager/cert-manager/releases/download/v1.7.1/cert-manager.yaml
4349
```
4450

45-
More specifics can be found in the
46-
[cert-manager install documentation](https://cert-manager.io/docs/installation/kubernetes/#installing-with-regular-manifests).
51+
## Option 2: Helm
52+
53+
Add cert-manager to your cluster
54+
[using Helm](https://cert-manager.io/docs/installation/helm/).
55+
56+
First, add the Helm repo:
57+
58+
```console
59+
helm repo add jetstack https://charts.jetstack.io
60+
```
61+
62+
Then, install cert-manager and create its namespace (check for the
63+
[latest cert-manager version](https://cert-manager.io/docs/installation/supported-releases/#installing-with-regular-manifests),
64+
since they may change)
65+
66+
```console
67+
helm install \
68+
cert-manager jetstack/cert-manager \
69+
--namespace cert-manager \
70+
--version v1.7.0 \ # update version if necessary
71+
--create-namespace \
72+
--set installCRDs=true
73+
```
74+
75+
You can find additional information in
76+
[cert-manager's installation docs](https://cert-manager.io/docs/installation/kubernetes/#installing-with-regular-manifests).
4777

4878
Once you've started the installation process, verify that all the pods are
4979
running:
@@ -177,11 +207,14 @@ However, to use all of the functionality you set up in this tutorial, use the
177207
following command instead:
178208

179209
```console
210+
# be sure to update the `stringValue` placeholder with the
211+
# proper value for your devurlsHostSecretName and hostSecretName
212+
180213
helm upgrade --install coder coder/coder --namespace coder \
181214
--version=<CODER_VERSION> \
182215
--set coderd.devurlsHost="*.coder.example.com" \
183-
--set coderd.tls.devurlsHostSecretName="coder-certs" \
184-
--set coderd.tls.hostSecretName="coder-certs" \
216+
--set coderd.tls.devurlsHostSecretName="coder-certs-stringValue" \
217+
--set coderd.tls.hostSecretName="coder-certs-stringValue" \
185218
--wait
186219
```
187220

guides/tls-certificates/cloudflare.md

+9-7
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ authority.
1414
> differently from earlier versions of Coder. Ensure that you're reading the
1515
> docs applicable to your Coder version.
1616
17-
This guide will show you how to install cert-manager v1.4.0 and set up your
18-
cluster to issue Let's Encrypt certificates for your Coder installation so that
19-
you can enable HTTPS on your Coder deployment.
17+
This guide will show you how to install cert-manager and set up your cluster to
18+
issue Let's Encrypt certificates for your Coder installation so that you can
19+
enable HTTPS on your Coder deployment.
2020

2121
> We recommend reviewing the official cert-manager
2222
> [documentation](https://cert-manager.io/docs/) if you encounter any issues or
@@ -34,7 +34,7 @@ You must have:
3434
## Step 1: Add cert-manager to your Kubernetes cluster
3535

3636
```console
37-
kubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.4.0/cert-manager.yaml
37+
kubectl apply -f https://github.com/cert-manager/cert-manager/releases/download/v1.7.1/cert-manager.yaml
3838
```
3939

4040
More specifics can be found in the
@@ -201,14 +201,16 @@ kubectl apply -f certificate.yaml
201201
## Step 4: Configure Coder to issue and use the certificates
202202

203203
If you're using the default LoadBalancer to access Coder, you can use the
204-
following helm values to use the certificate.
204+
following Helm values to use the certificate.
205205

206206
```yaml
207+
# be sure to update the `stringValue` placeholder with the
208+
# proper value for your devurlsHostSecretName and hostSecretName
207209
coderd:
208210
devurlsHost: "*.coder.example.com"
209211
tls:
210-
devurlsHostSecretName: "coder-certs"
211-
hostSecretName: "coder-certs"
212+
devurlsHostSecretName: "coder-certs-stringValue"
213+
hostSecretName: "coder-certs-stringValue"
212214
```
213215
214216
Be sure to change `coder.example.com` to the domain for your Coder deployment.

guides/tls-certificates/route53.md

+10-7
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ authority.
1414
> differently from earlier versions of Coder. Ensure that you're reading the
1515
> docs applicable to your Coder version.
1616
17-
This guide will show you how to install cert-manager v1.4.0 and set up your
18-
cluster to issue Let's Encrypt certificates for your Coder installation so that
19-
you can enable HTTPS on your Coder deployment. It will also show you how to
20-
configure your Coder hostname and dev URLs.
17+
This guide will show you how to install cert-manager and set up your cluster to
18+
issue Let's Encrypt certificates for your Coder installation so that you can
19+
enable HTTPS on your Coder deployment. It will also show you how to configure
20+
your Coder hostname and dev URLs.
2121

2222
## Prerequisites
2323

@@ -42,7 +42,7 @@ You should also:
4242
cert-manager:
4343

4444
```console
45-
kubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.4.0/cert-manager.yaml
45+
kubectl apply -f https://github.com/cert-manager/cert-manager/releases/download/v1.7.1/cert-manager.yaml
4646
```
4747

4848
1. Check that cert-manager installs correctly by running
@@ -199,11 +199,14 @@ However, to use all of the functionality you set up in this tutorial, use the
199199
following command instead:
200200

201201
```console
202+
# be sure to update the `stringValue` placeholder with the
203+
# proper value for your devurlsHostSecretName and hostSecretName
204+
202205
helm upgrade --install coder coder/coder --namespace coder \
203206
--version=<CODER_VERSION> \
204207
--set coderd.devurlsHost="*.coder.example.com" \
205-
--set coderd.tls.devurlsHostSecretName="coder-certs" \
206-
--set coderd.tls.hostSecretName="coder-certs" \
208+
--set coderd.tls.devurlsHostSecretName="coder-certs-stringValue" \
209+
--set coderd.tls.hostSecretName="coder-certs-stringValue" \
207210
--wait
208211
```
209212

0 commit comments

Comments
 (0)