Skip to content

feat: NLB Certificate autodiscovery using ssl-domains annotations #3269

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

Kavinraja-G
Copy link

@Kavinraja-G Kavinraja-G commented Jul 2, 2023

Issue

#3210

Description

  • Added a new annotation service.beta.kubernetes.io/aws-load-balancer-ssl-domains which helps to reuse the CertificateDiscovery implementation done for Ingress.
  • Auto discovery will happen only when the ssl-certs annotation not exists and ssl-domains annotation is provided. If both annotations are present, ssl-certs take precedence.

Checklist

  • Added tests that cover your change (if possible)
  • Added/modified documentation as required (such as the README.md, or the docs directory)
  • Manually tested
  • Made sure the title of the PR is a good description that can go into the release notes

BONUS POINTS checklist: complete for good vibes and maybe prizes?! 🤯

  • Backfilled missing tests for code in same general area 🎉
  • Refactored something and made the world a better place 🌟

@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Jul 2, 2023

CLA Signed

The committers listed above are authorized under a signed CLA.

@k8s-ci-robot k8s-ci-robot requested review from kishorj and M00nF1sh July 2, 2023 08:01
@k8s-ci-robot k8s-ci-robot added the cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. label Jul 2, 2023
@k8s-ci-robot
Copy link
Contributor

Welcome @Kavinraja-G!

It looks like this is your first PR to kubernetes-sigs/aws-load-balancer-controller 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-sigs/aws-load-balancer-controller has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Jul 2, 2023
@k8s-ci-robot
Copy link
Contributor

Hi @Kavinraja-G. Thanks for your PR.

I'm waiting for a kubernetes-sigs 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.

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.

@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Jul 2, 2023
@Kavinraja-G
Copy link
Author

@M00nF1sh -- This is my first PR out in AWS LB controller, please do guide me if anything I had missed.

QQ: I guess, we need to cover some tests around CertDiscovery for NLB since I incorporated a new annotation. There is no MockACMClients available to proceed with the tests, let me know from where I need to start for the UnitTests. Thanks & Happy to contribute! :)

@johngmyers
Copy link
Contributor

There's a NewMockCertDiscovery(). You should be building your unit tests around that.

@johngmyers
Copy link
Contributor

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jul 3, 2023
@Kavinraja-G
Copy link
Author

Kavinraja-G commented Jul 3, 2023

There's a NewMockCertDiscovery(). You should be building your unit tests around that.

@johngmyers The NewDefaultModelBuilder function now requires acmClient & logger need to be passed, so in order make the tests happy I would need the MockACMClient.

Let me know if I'm missing any. Thanks!

@johngmyers
Copy link
Contributor

@k8s-ci-robot please refactor that so one passes a CertDiscovery instead.

@Kavinraja-G
Copy link
Author

Kavinraja-G commented Jul 6, 2023

please refactor that so one passes a CertDiscovery instead

@johngmyers Thanks, I refactored the code to use CertDiscovery in this method, and now the tests are passing in my local.

Let me know if anything I need to do from my side to trigger this pull-aws-load-balancer-controller-unit-test job?

@Kavinraja-G Kavinraja-G requested a review from johngmyers July 6, 2023 11:38
@Kavinraja-G
Copy link
Author

@johngmyers Fixed the above suggestions on imports as well. Thanks!

@johngmyers
Copy link
Contributor

/lgtm
/assign @M00nF1sh

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 7, 2023
@Kavinraja-G
Copy link
Author

@M00nF1sh Are we good with this PR ? Let me know if anything I had missed, thanks!

@johngmyers
Copy link
Contributor

/retest

@Kavinraja-G
Copy link
Author

@johngmyers Any idea on why these workflows are failing?

@johngmyers
Copy link
Contributor

/retest

@Kavinraja-G Kavinraja-G force-pushed the feature/svc-acm-autodiscovery branch from 679f538 to 7c1b2f6 Compare June 1, 2024 16:28
@k8s-ci-robot
Copy link
Contributor

New changes are detected. LGTM label has been removed.

@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Jun 1, 2024
@Kavinraja-G Kavinraja-G force-pushed the feature/svc-acm-autodiscovery branch from 7c1b2f6 to a78c443 Compare June 1, 2024 16:37
@k8s-ci-robot
Copy link
Contributor

@Kavinraja-G: The following tests 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-aws-load-balancer-controller-unit-test a78c443 link true /test pull-aws-load-balancer-controller-unit-test
pull-aws-load-balancer-controller-e2e-test a78c443 link true /test pull-aws-load-balancer-controller-e2e-test

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.

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-sigs/prow repository. I understand the commands that are listed here.

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle stale
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Aug 30, 2024
@Kavinraja-G
Copy link
Author

@M00nF1sh Anything you need help on this PR?

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Aug 31, 2024
@shraddhabang shraddhabang added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 8, 2024
@PG2000
Copy link

PG2000 commented Dec 20, 2024

@Kavinraja-G, @M00nF1sh can i help out here. I'm interested in this feature to be completed.

@Kavinraja-G
Copy link
Author

@Kavinraja-G, @M00nF1sh can i help out here. I'm interested in this feature to be completed.

This is almost done @PG2000 Need further comments from @M00nF1sh on what needs to be done here.

@PG2000
Copy link

PG2000 commented Jan 10, 2025

@Kavinraja-G, @M00nF1sh can i help out here. I'm interested in this feature to be completed.

This is almost done @PG2000 Need further comments from @M00nF1sh on what needs to be done here.

@Kavinraja-G maybe you could rebase this and maybe @kishorj can help here

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle stale
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 10, 2025
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle rotten
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels May 10, 2025
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Reopen this PR with /reopen
  • Mark this PR as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close

@k8s-ci-robot
Copy link
Contributor

@k8s-triage-robot: Closed this PR.

In response to this:

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Reopen this PR with /reopen
  • Mark this PR as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close

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-sigs/prow repository.

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. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants