Merge pull request #312 from Mikulas/pr/cert-crd-alias
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Add default shortNames to certificates CRD Defaults to `[cert, certs]` and is configurable with `certificateCRDShortNames` parameter. **What this PR does / why we need it**: Simplifies manual certificate management with kubectl. Fixes #311 <div name="review-notes" /> **Special notes for your reviewer**: Instead of a boolean switch do/dont include the shortNames, the value defines the aliases. This may be handy if anybody prefers `[crt, crts]` instead. I'm not too keen on the `certificateCRDShortNames` variable name. It might be better to use `Resource` instead of `CRD` to be consistent with the `createCustomResource` var. Other CRDs are probably ok without an alias, but other people workflows may differ. Should these also be configurable? In that case, the variables could be `shortNames: {certificates: [], …}`. **Release note**: ```release-note Add Certificate CRD shortnames `cert` and `certs`. This is configurable in the Helm Chart with `certificateResourceShortNames`. ```
This commit is contained in:
commit
362735f8f1
@ -58,6 +58,7 @@ The following tables lists the configurable parameters of the cert-manager chart
|
||||
| `image.pullPolicy` | Image pull policy | `IfNotPresent` |
|
||||
| `replicaCount` | Number of cert-manager replicas | `1` |
|
||||
| `createCustomResource` | Create CRD/TPR with this release | `true` |
|
||||
| `certificateResourceShortNames` | Custom aliases for Certificate CRD | `["cert", "certs"]` |
|
||||
| `extraArgs` | Optional flags for cert-manager | `[]` |
|
||||
| `rbac.create` | If `true`, create and use RBAC resources | `true`
|
||||
| `serviceAccount.create` | If `true`, create a new service account | `true`
|
||||
|
||||
@ -11,8 +11,12 @@ metadata:
|
||||
spec:
|
||||
group: certmanager.k8s.io
|
||||
version: v1alpha1
|
||||
scope: Namespaced
|
||||
names:
|
||||
kind: Certificate
|
||||
plural: certificates
|
||||
scope: Namespaced
|
||||
{{- if .Values.certificateResourceShortNames }}
|
||||
shortNames:
|
||||
{{ toYaml .Values.certificateResourceShortNames | indent 6 }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
@ -10,6 +10,8 @@ image:
|
||||
|
||||
createCustomResource: true
|
||||
|
||||
certificateResourceShortNames: ["cert", "certs"]
|
||||
|
||||
rbac:
|
||||
# Specifies whether RBAC resources should be created
|
||||
create: true
|
||||
|
||||
@ -12,7 +12,11 @@ metadata:
|
||||
spec:
|
||||
group: certmanager.k8s.io
|
||||
version: v1alpha1
|
||||
scope: Namespaced
|
||||
names:
|
||||
kind: Certificate
|
||||
plural: certificates
|
||||
scope: Namespaced
|
||||
shortNames:
|
||||
- cert
|
||||
- certs
|
||||
|
||||
@ -12,7 +12,11 @@ metadata:
|
||||
spec:
|
||||
group: certmanager.k8s.io
|
||||
version: v1alpha1
|
||||
scope: Namespaced
|
||||
names:
|
||||
kind: Certificate
|
||||
plural: certificates
|
||||
scope: Namespaced
|
||||
shortNames:
|
||||
- cert
|
||||
- certs
|
||||
|
||||
Loading…
Reference in New Issue
Block a user