Skip to content

Support loading controller configuration from a versioned file - #5337

Merged
jetstack-bot merged 3 commits into
cert-manager:masterfrom
AcidLeroy:controller-configuration-file
Jul 31, 2023
Merged

jetstack-bot merged 3 commits into
cert-manager:masterfrom
AcidLeroy:controller-configuration-file

Conversation

@AcidLeroy

@AcidLeroy AcidLeroy commented Jul 25, 2022 •

Copy link
Copy Markdown
Contributor

Pull Request Motivation

Closes #5160

The motivation for this pull request is to add a version config file for the cert-manager controller. This follows the guidance from Versioned Component Configuration Files. In addition, this closely follows the pattern defined in PR: #4546.

Checklist

Kind

/kind feature

Release Note

The cert-manager controller options are now configurable using a configuration file.

@jetstack-bot jetstack-bot added release-note-none Denotes a PR that doesn't merit a release note. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. dco-signoff: no Indicates that at least one commit in this pull request is missing the DCO sign-off message. needs-kind Indicates a PR lacks a `kind/foo` label and requires one. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jul 25, 2022
@jetstack-bot

Copy link
Copy Markdown
Contributor

Hi @AcidLeroy. Thanks for your PR.

I'm waiting for a cert-manager member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@jetstack-bot jetstack-bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. area/api Indicates a PR directly modifies the 'pkg/apis' directory needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Jul 25, 2022
@jetstack-bot jetstack-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 17, 2022
@jetstack-bot

Copy link
Copy Markdown
Contributor

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close.
Send feedback to jetstack.
/lifecycle stale

@jetstack-bot jetstack-bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Feb 15, 2023
@irbekrm

irbekrm commented Mar 9, 2023

Copy link
Copy Markdown
Contributor

/remove-lifecycle stale

@jetstack-bot jetstack-bot removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Mar 9, 2023
@AcidLeroy
AcidLeroy force-pushed the controller-configuration-file branch from 0981a5c to c3a4b41 Compare March 10, 2023 17:48
@jetstack-bot jetstack-bot added dco-signoff: yes Indicates that all commits in the pull request have the valid DCO sign-off message. and removed dco-signoff: no Indicates that at least one commit in this pull request is missing the DCO sign-off message. labels Mar 10, 2023
@AcidLeroy
AcidLeroy force-pushed the controller-configuration-file branch 8 times, most recently from 8e3ebe0 to 3992542 Compare March 15, 2023 22:38
@AcidLeroy
AcidLeroy force-pushed the controller-configuration-file branch from 3992542 to 357829f Compare March 17, 2023 23:29
@AcidLeroy
AcidLeroy force-pushed the controller-configuration-file branch from 9b2cf0a to 9fbd4cc Compare July 19, 2023 17:41
@AcidLeroy AcidLeroy changed the title WIP: Support loading controller configuration from a versioned file Support loading controller configuration from a versioned file Jul 19, 2023
@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 Jul 19, 2023
@inteon inteon self-assigned this Jul 20, 2023
@inteon
inteon force-pushed the controller-configuration-file branch from 9fbd4cc to 351b4be Compare July 20, 2023 08:54
@jetstack-bot

jetstack-bot commented Jul 20, 2023 •

Copy link
Copy Markdown
Contributor

@AcidLeroy: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
pull-cert-manager-master-e2e-v1-26 556f90d link true /test pull-cert-manager-master-e2e-v1-26

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@inteon
inteon force-pushed the controller-configuration-file branch from 351b4be to cab2e8e Compare July 20, 2023 09:00

@inteon inteon left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thank you for making this big improvement.
I rebased the PR and removed some unnecessary LICENSES diffs.
I still have a couple of questions, some of them might just be me not being an expert wrt. this config-file approach.

Comment thread cmd/controller/app/controller.go Resolved
Comment thread cmd/controller/app/start.go Resolved
@AcidLeroy
AcidLeroy force-pushed the controller-configuration-file branch 4 times, most recently from 38caf7f to 7b83211 Compare July 20, 2023 17:51
- This  commit changes the internal config to have fewer number of
  optional parameters.  It changes the types to match the ones that are
  already present in https://github.com/kubernetes/apimachinery/blob/master/pkg/apis/meta/v1/conversion.go
  so that custom converters do not have to be written for types "int"
  and "float32".

Signed-off-by: Cody W. Eilar <[email protected]>
- Needed to add custom conversion functions to handle conversions from
  public facing types to internal ones.

Signed-off-by: Cody W. Eilar <[email protected]>
logsapi "k8s.io/component-base/logs/api/v1"
)

func Convert_v1alpha1_ControllerConfiguration_To_controller_ControllerConfiguration(in *v1alpha1.ControllerConfiguration, out *controller.ControllerConfiguration, s conversion.Scope) error {

@inteon inteon Jul 28, 2023 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

nit: Do we need these 2 functions? Are they not auto-generated?

@inteon

inteon commented Jul 28, 2023

Copy link
Copy Markdown
Member

This is a great improvement @AcidLeroy!
Thank you for resolving all my questions.
/approve
/lgtm
/hold I have one optional nit, please let me know if you want to merge without fixing it.

@jetstack-bot

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: AcidLeroy, inteon

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

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@inteon

inteon commented Jul 31, 2023

Copy link
Copy Markdown
Member

/unhold
We can fix that convert function later if necessary.

@inteon

inteon commented Jul 31, 2023

Copy link
Copy Markdown
Member

@AcidLeroy Could you also create a website documentation PR for this improvement?

@inteon

inteon commented Jul 31, 2023

Copy link
Copy Markdown
Member

@AcidLeroy Any further improvements can be made in seperate PRs.

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. area/acme Indicates a PR directly modifies the ACME Issuer code area/api Indicates a PR directly modifies the 'pkg/apis' directory area/deploy Indicates a PR modifies deployment configuration area/testing Issues relating to testing dco-signoff: yes Indicates that all commits in the pull request have the valid DCO sign-off message. kind/feature Categorizes issue or PR as related to a new feature. lgtm Indicates that a PR is ready to be merged. ok-to-test release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support loading controller configuration from a versioned file

4 participants