Skip to content
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

fix: Update spot pricing even in Isolated VPC #5704

Merged
merged 29 commits into from
Mar 2, 2024
Merged

Conversation

liafizan
Copy link
Contributor

Fixes ##5587

Description
Spot pricing uses EC2 api and a check in code base disabled spot pricing check when --isolated-vpc flag was used. Removed condition which will allow spot prices to be updated when in isolated-vpc

How was this change tested?
Manual testing. Tried adding a test in pricing suite but it did not help since pricing controller itself was enabled which deemed this test unnecessary.

Does this change impact docs?

  • [x ] Yes, PR includes docs updates
  • Yes, issue opened: #
  • [] No

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@liafizan liafizan requested a review from a team as a code owner February 21, 2024 03:44
@liafizan liafizan requested a review from jigisha620 February 21, 2024 03:44
Copy link

netlify bot commented Feb 21, 2024

Deploy Preview for karpenter-docs-prod canceled.

Name Link
🔨 Latest commit 66e9cb7
🔍 Latest deploy log https://app.netlify.com/sites/karpenter-docs-prod/deploys/65e129aec7e372000804cd5e

@coveralls
Copy link

coveralls commented Feb 22, 2024

Pull Request Test Coverage Report for Build 8104908898

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 9 of 9 (100.0%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.02%) to 82.661%

Totals Coverage Status
Change from base Build 8103228577: 0.02%
Covered Lines: 5263
Relevant Lines: 6367

💛 - Coveralls

@engedaam
Copy link
Contributor

Make sure you run make presubmit and make docgen which should make changes to get the ci-tests to pass

Copy link
Contributor

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

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

Thanks for adding the change!

charts/karpenter/README.md Outdated Show resolved Hide resolved
pkg/operator/options/options.go Outdated Show resolved Hide resolved
pkg/providers/pricing/controller.go Outdated Show resolved Hide resolved
pkg/providers/pricing/suite_test.go Outdated Show resolved Hide resolved
@jonathan-innis
Copy link
Contributor

@liafizan Did you validate this on your own private cluster?

@liafizan
Copy link
Contributor Author

@liafizan Did you validate this on your own private cluster?

Hey @jonathan-innis. I tested my changes in local cluster. Though not exhaustive but I can validate --isolated-vpc cases and see that both are invoked now when isolated-vpc is true or else only spot pricing is updated.

pkg/providers/pricing/controller.go Outdated Show resolved Hide resolved
pkg/controllers/controllers.go Show resolved Hide resolved
pkg/providers/pricing/suite_test.go Outdated Show resolved Hide resolved
@jonathan-innis jonathan-innis self-assigned this Mar 2, 2024
Copy link
Contributor

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants