Skip to content

Commit d2787d6

Browse files
author
Trevor Ackerman
committed
update dns delegation, add details for log level
1 parent 9d25ce9 commit d2787d6

File tree

6 files changed

+76
-6
lines changed

6 files changed

+76
-6
lines changed

content/docs/cli/cainjector.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,6 @@ Flags:
4646
--metrics-tls-private-key-file string path to the file containing the TLS private key to serve metrics with
4747
--namespace string If set, this limits the scope of cainjector to a single namespace. If set, cainjector will not update resources with certificates outside of the configured namespace.
4848
--profiler-address string The host and port that Go profiler should listen on, i.e localhost:6060. Ensure that profiler is not exposed on a public address. Profiler will be served at /debug/pprof. (default "localhost:6060")
49-
-v, --v Level number for the log level verbosity
49+
-v, --v Level number for the log level verbosity, 0 for Error, 1 for Warn, 2 for Info, 3 for Extended Info, 4 for Debug, 5 for Trace, default is 2
5050
--vmodule pattern=N,... comma-separated list of pattern=N settings for file-filtered logging (only works for text log format)
5151
```

content/docs/cli/cmctl.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ Flags:
2626
-h, --help help for cmctl
2727
--log-flush-frequency duration Maximum number of seconds between log flushes (default 5s)
2828
--logging-format string Sets the log format. Permitted formats: "json" (gated by LoggingBetaOptions), "text". (default "text")
29-
-v, --v Level[=2] number for the log level verbosity
29+
-v, --v Level number for the log level verbosity, 0 for Error, 1 for Warn, 2 for Info, 3 for Extended Info, 4 for Debug, 5 for Trace, default is 2
3030
--vmodule pattern=N,... comma-separated list of pattern=N settings for file-filtered logging (only works for text log format)
3131
3232
Use "cmctl [command] --help" for more information about a command.

content/docs/cli/controller.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,6 @@ Flags:
7878
--metrics-tls-private-key-file string path to the file containing the TLS private key to serve with
7979
--namespace string If set, this limits the scope of cert-manager to a single namespace and ClusterIssuers are disabled. If not specified, all namespaces will be watched
8080
--profiler-address string The host and port that Go profiler should listen on, i.e localhost:6060. Ensure that profiler is not exposed on a public address. Profiler will be served at /debug/pprof. (default "localhost:6060")
81-
-v, --v Level number for the log level verbosity
81+
-v, --v Level number for the log level verbosity, 0 for Error, 1 for Warn, 2 for Info, 3 for Extended Info, 4 for Debug, 5 for Trace, default is 2
8282
--vmodule pattern=N,... comma-separated list of pattern=N settings for file-filtered logging (only works for text log format)
8383
```

content/docs/cli/startupapicheck.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Flags:
1717
-h, --help help for startupapicheck
1818
--log-flush-frequency duration Maximum number of seconds between log flushes (default 5s)
1919
--logging-format string Sets the log format. Permitted formats: "json" (gated by LoggingBetaOptions), "text". (default "text")
20-
-v, --v Level[=2] number for the log level verbosity
20+
-v, --v Level number for the log level verbosity, 0 for Error, 1 for Warn, 2 for Info, 3 for Extended Info, 4 for Debug, 5 for Trace, default is 2
2121
--vmodule pattern=N,... comma-separated list of pattern=N settings for file-filtered logging (only works for text log format)
2222
2323
Use "startupapicheck [command] --help" for more information about a command.

content/docs/cli/webhook.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,6 @@ Flags:
4848
--tls-cipher-suites strings Comma-separated list of cipher suites for the server. If omitted, the default Go cipher suites will be used. Possible values: TLS_AES_128_GCM_SHA256,TLS_AES_256_GCM_SHA384,TLS_CHACHA20_POLY1305_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA,TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305,TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256,TLS_ECDHE_ECDSA_WITH_RC4_128_SHA,TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305,TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256,TLS_ECDHE_RSA_WITH_RC4_128_SHA,TLS_RSA_WITH_3DES_EDE_CBC_SHA,TLS_RSA_WITH_AES_128_CBC_SHA,TLS_RSA_WITH_AES_128_CBC_SHA256,TLS_RSA_WITH_AES_128_GCM_SHA256,TLS_RSA_WITH_AES_256_CBC_SHA,TLS_RSA_WITH_AES_256_GCM_SHA384,TLS_RSA_WITH_RC4_128_SHA
4949
--tls-min-version string Minimum TLS version supported. If omitted, the default Go minimum version will be used. Possible values: VersionTLS10, VersionTLS11, VersionTLS12, VersionTLS13
5050
--tls-private-key-file string path to the file containing the TLS private key to serve with
51-
-v, --v Level number for the log level verbosity
51+
-v, --v Level number for the log level verbosity, 0 for Error, 1 for Warn, 2 for Info, 3 for Extended Info, 4 for Debug, 5 for Trace, default is 2
5252
--vmodule pattern=N,... comma-separated list of pattern=N settings for file-filtered logging (only works for text log format)
5353
```

content/docs/configuration/acme/dns01/README.md

Lines changed: 71 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,11 +84,19 @@ By default, cert-manager will not follow CNAME records pointing to subdomains.
8484

8585
If granting cert-manager access to the root DNS zone is not desired, then the
8686
`_acme-challenge.example.com` subdomain can instead be delegated to some other,
87-
less privileged domain (`less-privileged.example.org`). This could be achieved in the following way. Say, one has two zones:
87+
less privileged domain.
88+
89+
### Nonmatching Subdomains
90+
91+
Delegation could be achieved in the following way. Say, one has two zones:
8892

8993
* `example.com`
9094
* `less-privileged.example.org`
9195

96+
Notice how the above two zones have different Top Level Domains (i.e. `.com` vs `.org`).
97+
This means cert-manager will be querying for expected `TXT` records against authoritative nameservers
98+
for `example.org` instead of authoritative nameservers for `example.com`.
99+
92100
1. Create a CNAME record pointing to this less privileged domain:
93101
```
94102
_acme-challenge.example.com IN CNAME _acme-challenge.less-privileged.example.org.
@@ -124,6 +132,68 @@ spec:
124132
...
125133
```
126134

135+
### Matching Subdomains and Multiple DNS Providers
136+
137+
Be aware of hurdles that exist when the two zones share the same subdomain, for example:
138+
139+
* `example.com`
140+
* `less-privileged.example.com`
141+
142+
This is different than the previous example where we used `.org` for our delegated zone.
143+
144+
When different providers manage each of the above domains you must take additional steps.
145+
146+
The following illustrates how to delegate when Google CloudDNS manages the domain
147+
`less-privileged.example.com` and a separate DNS provider manages the domain `example.com`.
148+
149+
1. Create a CNAME record pointing to this less privileged domain:
150+
Create this record in the DNS Provider that manages the `example.com.` domain.
151+
```
152+
_acme-challenge.example.com IN CNAME _acme-challenge.less-privileged.example.com.
153+
```
154+
155+
2. Create NS records pointing to Google CloudDNS for this less privileged domain:
156+
This is required in order for the DNS provider managing `example.com` to be able to
157+
delegate answers for `less-privileged.example.com` to Google CloudDNS. Otherwise
158+
DNS queries by cert-manager for TXT records will receive an `NXDOMAIN` response
159+
and fail.
160+
161+
Create this record in the DNS Provider that manages the `example.com.` domain.
162+
```
163+
less-privileged.example.com. 3600 IN NS ns-cloud-a1.googledomains.com.
164+
less-privileged.example.com. 3600 IN NS ns-cloud-a2.googledomains.com.
165+
less-privileged.example.com. 3600 IN NS ns-cloud-a3.googledomains.com.
166+
less-privileged.example.com. 3600 IN NS ns-cloud-a4.googledomains.com.
167+
```
168+
169+
3. Grant cert-manager rights to update less privileged `less-privileged.example.com` zone
170+
171+
4. Provide configuration/credentials for updating this less privileged zone
172+
and add an additional field into the relevant `dns01` solver. Note that `selector`
173+
field is now pointing to the delegated zone `less-privileged.example.com`.
174+
175+
```yaml
176+
apiVersion: cert-manager.io/v1
177+
kind: Issuer
178+
metadata:
179+
...
180+
spec:
181+
acme:
182+
...
183+
solvers:
184+
- selector:
185+
dnsZones:
186+
- 'less-privileged.example.com'
187+
dns01:
188+
# Valid values are None and Follow
189+
cnameStrategy: Follow
190+
cloudDNS:
191+
# The ID of the GCP project
192+
project: $PROJECT_ID
193+
...
194+
```
195+
196+
### Multiple Subdomains Requiring Separate Certificates
127197
If you have a multitude of (sub)domains requiring separate certificates,
128198
it is possible to share an aliased less-privileged domain. To achieve it one should
129199
create a CNAME record for each (sub)domain like this:

0 commit comments

Comments
 (0)