Skip to content

Add default shortNames to certificates CRD - #312

Merged
jetstack-ci-bot merged 1 commit into
cert-manager:masterfrom
Mikulas:pr/cert-crd-alias
Feb 21, 2018
Merged

jetstack-ci-bot merged 1 commit into
cert-manager:masterfrom
Mikulas:pr/cert-crd-alias

Conversation

@Mikulas

@Mikulas Mikulas commented Feb 12, 2018 •

Copy link
Copy Markdown
Contributor

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

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:

Add Certificate CRD shortnames `cert` and `certs`. This is configurable in the Helm Chart with `certificateResourceShortNames`.

@jetstack-bot jetstack-bot added the release-note Denotes a PR that will be considered when it comes time to generate release notes. label Feb 12, 2018
@jetstack-bot
jetstack-bot requested a review from munnerz February 12, 2018 15:01
@jetstack-bot jetstack-bot added size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Feb 12, 2018
@munnerz

munnerz commented Feb 12, 2018

Copy link
Copy Markdown
Member

/ok-to-test

@jetstack-bot jetstack-bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Feb 12, 2018
@munnerz

munnerz commented Feb 12, 2018

Copy link
Copy Markdown
Member

@Mikulas instead of manually editing the deployment files in docs/deploy, you should run ./hack/update-deploy-gen.sh in order to regenerate them 😄

@Mikulas

Mikulas commented Feb 12, 2018

Copy link
Copy Markdown
Contributor Author

@munnerz oh thanks 😅 makes sense

spec:
group: certmanager.k8s.io
version: v1alpha1
scope: Namespaced

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is not meaningless, I wanted to prevent an extra newline generated by toYaml between the list and scope. It's a tradeoff between consistency with other templates, Helm Template best practices and keeping the release as small as possible.

@Mikulas

Mikulas commented Feb 15, 2018

Copy link
Copy Markdown
Contributor Author

The tests pass, but please see the notes #312 (comment).

/assign @munnerz

@Mikulas Mikulas changed the title Add default shortNames to certificates CRD WIP: Add default shortNames to certificates CRD Feb 15, 2018
@jetstack-bot jetstack-bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Feb 15, 2018
@munnerz munnerz added this to the v0.3 milestone Feb 21, 2018
@munnerz

munnerz commented Feb 21, 2018

Copy link
Copy Markdown
Member

Sorry for the delay - I like your suggestion: certificateResourceShortNames 😄

@munnerz

munnerz commented Feb 21, 2018

Copy link
Copy Markdown
Member

Thanks!

/approve
/lgtm

@jetstack-bot jetstack-bot added lgtm Indicates that a PR is ready to be merged. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Feb 21, 2018
@munnerz

munnerz commented Feb 21, 2018

Copy link
Copy Markdown
Member

If you could update the release note and remove WIP from the title, this should then be automatically merged 😄

@munnerz

munnerz commented Feb 21, 2018

Copy link
Copy Markdown
Member

/retest

@Mikulas Mikulas changed the title WIP: Add default shortNames to certificates CRD Add default shortNames to certificates CRD Feb 21, 2018
@jetstack-bot jetstack-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Feb 21, 2018
@Mikulas

Mikulas commented Feb 21, 2018

Copy link
Copy Markdown
Contributor Author

/retest

Defaults to [cert, certs] and is configurable with
`certificateCRDShortNames` parameter.

[Closes cert-manager#311]
@jetstack-ci-bot

Copy link
Copy Markdown
Contributor

/test all [submit-queue is verifying that this PR is safe to merge]

@Mikulas

Mikulas commented Feb 21, 2018

Copy link
Copy Markdown
Contributor Author

@munnerz Thanks :) Will the Submit Queue automatically squash into a single commit? I've kept it separated as fixups for review.

@munnerz

munnerz commented Feb 21, 2018 via email

Copy link
Copy Markdown
Member

@munnerz

munnerz commented Feb 21, 2018

Copy link
Copy Markdown
Member

/lgtm

@jetstack-bot jetstack-bot added the lgtm Indicates that a PR is ready to be merged. label Feb 21, 2018
@jetstack-bot

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: munnerz

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@munnerz

munnerz commented Feb 21, 2018 via email

Copy link
Copy Markdown
Member

@jetstack-ci-bot

Copy link
Copy Markdown
Contributor

Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions here.

@jetstack-ci-bot
jetstack-ci-bot merged commit 362735f into cert-manager:master Feb 21, 2018
@Mikulas

Mikulas commented Feb 21, 2018

Copy link
Copy Markdown
Contributor Author

Awesome, thank you :)

munnerz pushed a commit to munnerz/charts-1 that referenced this pull request Apr 23, 2018
* f117e6e8 Merge branch 'master' into patch-1
* Add Endpoints back into the cert-manager RBAC policy (cert-manager/cert-manager#343)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* Use cert-manager & boulder installed via helm in e2e tests. Run tests with Prow. (cert-manager/cert-manager#216)
munnerz pushed a commit to munnerz/charts-1 that referenced this pull request Apr 23, 2018
* f117e6e8 Merge branch 'master' into patch-1
* Add Endpoints back into the cert-manager RBAC policy (cert-manager/cert-manager#343)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* Use cert-manager & boulder installed via helm in e2e tests. Run tests with Prow. (cert-manager/cert-manager#216)
munnerz pushed a commit to munnerz/charts-1 that referenced this pull request Apr 23, 2018
* f117e6e8 Merge branch 'master' into patch-1
* Add Endpoints back into the cert-manager RBAC policy (cert-manager/cert-manager#343)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* Use cert-manager & boulder installed via helm in e2e tests. Run tests with Prow. (cert-manager/cert-manager#216)
munnerz pushed a commit to munnerz/charts that referenced this pull request Apr 24, 2018
* f117e6e8 Merge branch 'master' into patch-1
* Add Endpoints back into the cert-manager RBAC policy (cert-manager/cert-manager#343)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* Use cert-manager & boulder installed via helm in e2e tests. Run tests with Prow. (cert-manager/cert-manager#216)
munnerz added a commit to munnerz/charts-1 that referenced this pull request Apr 24, 2018
* f117e6e8 Merge branch 'master' into patch-1
* Add Endpoints back into the cert-manager RBAC policy (cert-manager/cert-manager#343)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* Use cert-manager & boulder installed via helm in e2e tests. Run tests with Prow. (cert-manager/cert-manager#216)
munnerz added a commit to munnerz/charts-1 that referenced this pull request May 24, 2018
* Bump chart and manifests for v0.3.0 release (cert-manager/cert-manager#575)
* add pod labels (cert-manager/cert-manager#563)
* Add leaderElection.namespace option to helm chart (cert-manager/cert-manager#548)
* Add clusterResourceNamespace option to Helm chart (cert-manager/cert-manager#547)
* Fix ingress-shim cli flags (cert-manager/cert-manager#526)
* Create chart OWNERS (cert-manager/cert-manager#528)
* Link ingress-shim into main controller binary (cert-manager/cert-manager#502)
* readthedocs documentation rewrite (cert-manager/cert-manager#428)
* add selector, as otherwise it fails on GKE k8s v1.9.x (cert-manager/cert-manager#440)
* Add podAnnotations (cert-manager/cert-manager#387)
* Document common ingressShim.extraArgs use case in chart (cert-manager/cert-manager#382)
* Helm Chart: Add support for affinity and tolerations (cert-manager/cert-manager#350)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Create a Namespace resource as part of the static manifest bundle (cert-manager/cert-manager#340)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* fix: Use ConfigMaps for leaderelection (cert-manager/cert-manager#327)
k8s-ci-robot pushed a commit to helm/charts that referenced this pull request May 24, 2018
* Bump chart and manifests for v0.3.0 release (cert-manager/cert-manager#575)
* add pod labels (cert-manager/cert-manager#563)
* Add leaderElection.namespace option to helm chart (cert-manager/cert-manager#548)
* Add clusterResourceNamespace option to Helm chart (cert-manager/cert-manager#547)
* Fix ingress-shim cli flags (cert-manager/cert-manager#526)
* Create chart OWNERS (cert-manager/cert-manager#528)
* Link ingress-shim into main controller binary (cert-manager/cert-manager#502)
* readthedocs documentation rewrite (cert-manager/cert-manager#428)
* add selector, as otherwise it fails on GKE k8s v1.9.x (cert-manager/cert-manager#440)
* Add podAnnotations (cert-manager/cert-manager#387)
* Document common ingressShim.extraArgs use case in chart (cert-manager/cert-manager#382)
* Helm Chart: Add support for affinity and tolerations (cert-manager/cert-manager#350)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Create a Namespace resource as part of the static manifest bundle (cert-manager/cert-manager#340)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* fix: Use ConfigMaps for leaderelection (cert-manager/cert-manager#327)
cesaralbloz pushed a commit to cesaralbloz/charts that referenced this pull request May 25, 2018
* Bump chart and manifests for v0.3.0 release (cert-manager/cert-manager#575)
* add pod labels (cert-manager/cert-manager#563)
* Add leaderElection.namespace option to helm chart (cert-manager/cert-manager#548)
* Add clusterResourceNamespace option to Helm chart (cert-manager/cert-manager#547)
* Fix ingress-shim cli flags (cert-manager/cert-manager#526)
* Create chart OWNERS (cert-manager/cert-manager#528)
* Link ingress-shim into main controller binary (cert-manager/cert-manager#502)
* readthedocs documentation rewrite (cert-manager/cert-manager#428)
* add selector, as otherwise it fails on GKE k8s v1.9.x (cert-manager/cert-manager#440)
* Add podAnnotations (cert-manager/cert-manager#387)
* Document common ingressShim.extraArgs use case in chart (cert-manager/cert-manager#382)
* Helm Chart: Add support for affinity and tolerations (cert-manager/cert-manager#350)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Create a Namespace resource as part of the static manifest bundle (cert-manager/cert-manager#340)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* fix: Use ConfigMaps for leaderelection (cert-manager/cert-manager#327)
voron pushed a commit to dysnix/helm-charts that referenced this pull request Sep 5, 2018
* Bump chart and manifests for v0.3.0 release (cert-manager/cert-manager#575)
* add pod labels (cert-manager/cert-manager#563)
* Add leaderElection.namespace option to helm chart (cert-manager/cert-manager#548)
* Add clusterResourceNamespace option to Helm chart (cert-manager/cert-manager#547)
* Fix ingress-shim cli flags (cert-manager/cert-manager#526)
* Create chart OWNERS (cert-manager/cert-manager#528)
* Link ingress-shim into main controller binary (cert-manager/cert-manager#502)
* readthedocs documentation rewrite (cert-manager/cert-manager#428)
* add selector, as otherwise it fails on GKE k8s v1.9.x (cert-manager/cert-manager#440)
* Add podAnnotations (cert-manager/cert-manager#387)
* Document common ingressShim.extraArgs use case in chart (cert-manager/cert-manager#382)
* Helm Chart: Add support for affinity and tolerations (cert-manager/cert-manager#350)
* Set default cluster resource namespace to current pod namespace (cert-manager/cert-manager#329)
* Create a Namespace resource as part of the static manifest bundle (cert-manager/cert-manager#340)
* Add default shortNames to certificates CRD (cert-manager/cert-manager#312)
* fix: Use ConfigMaps for leaderelection (cert-manager/cert-manager#327)

Signed-off-by: voron <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants