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

Configure HTTP proxy for components running in the seed #4459

Merged
merged 12 commits into from
Oct 9, 2019

Conversation

alvaroaleman
Copy link
Contributor

What this PR does / why we need it:

  • Introduces the ProxySettings struct into the api which holds proxy settings
  • Extends the SeedSpec with an optional ProxySettings property
  • Replaces the proxy settings in the NodeSettings with an embedded ProxySettings
  • Adds a SetDefaults func for the seed that sets the ProxySettings of all Datacenters to whats configured on the SeedSpec if unset
  • Calls the seeds SetDefaults in both the SeedGetter and SeedsGetter
  • Uses the ProxySettings from the seed to set to populate proxy env vars in
    • Kube apiserver
    • Kube controller-manager
    • machine-controller
    • machine-controller-webhook
    • openshift kube apiserver
    • openshift kube controller-manager

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #4399

Special notes for your reviewer:

Documentation:

Does this PR introduce a user-facing change?:

It is now possible to configure an http proxy on a Seed. This will result in the proxy being used for
all control plane pods in that seed that talk to a cloudprovider and for all machines in that Seed, unless its overriden on Datacenter level.

@kubermatic-bot kubermatic-bot added the release-note Denotes a PR that will be considered when it comes time to generate release notes. label Oct 9, 2019
@kubermatic-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alvaroaleman

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

The pull request process is described here

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

@kubermatic-bot kubermatic-bot added approved Indicates a PR has been approved by an approver from all required OWNERS files. team/lifecycle size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Oct 9, 2019
@@ -32,6 +32,20 @@ type Seed struct {
Spec SeedSpec `json:"spec"`
}

func (s *Seed) SetDefaults() {
Copy link
Contributor

Choose a reason for hiding this comment

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

Will we move this to the validation hook at some point?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ValidationHooks can only act on writing requests, not on reading ones. So no, which is not quite ideal

We could copy it into the Datacenters with a webhook on create/update, but then the Datacenters proxy settings don't get updated when the Seed proxy settings are changed, which is also not great.

Copy link
Contributor

Choose a reason for hiding this comment

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

Agreed.

@xrstf
Copy link
Contributor

xrstf commented Oct 9, 2019

/lgtm

@kubermatic-bot kubermatic-bot added the lgtm Indicates that a PR is ready to be merged. label Oct 9, 2019
@kubermatic-bot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 40ecd4066702be204edd3879693373d9033e9016

@kubermatic-triage-bot
Copy link

/retest
This bot automatically retries jobs that failed/flaked on approved PRs

Review the full test history

Silence the bot with an /lgtm cancel or /hold comment for consistent failures.

Also, here is a cat.
/meow

@kubermatic-bot
Copy link
Contributor

@kubermatic-triage-bot: cat image

In response to this:

/retest
This bot automatically retries jobs that failed/flaked on approved PRs

Review the full test history

Silence the bot with an /lgtm cancel or /hold comment for consistent failures.

Also, here is a cat.
/meow

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.

@alvaroaleman
Copy link
Contributor Author

/hold

@kubermatic-bot kubermatic-bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 9, 2019
@kubermatic-bot kubermatic-bot removed the lgtm Indicates that a PR is ready to be merged. label Oct 9, 2019
@xrstf
Copy link
Contributor

xrstf commented Oct 9, 2019

/lgtm

@kubermatic-bot kubermatic-bot added the lgtm Indicates that a PR is ready to be merged. label Oct 9, 2019
@kubermatic-bot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 42c0d2338445f21a79ea30832f48ec3fdd044208

@kubermatic-bot kubermatic-bot removed the lgtm Indicates that a PR is ready to be merged. label Oct 9, 2019
@xrstf
Copy link
Contributor

xrstf commented Oct 9, 2019

/lgtm

@kubermatic-bot kubermatic-bot added the lgtm Indicates that a PR is ready to be merged. label Oct 9, 2019
@kubermatic-bot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 8cc0d365f524d9c6a0018aec04b1acafa7d8eecb

@alvaroaleman
Copy link
Contributor Author

/hold cancel

@kubermatic-bot kubermatic-bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 9, 2019
@kubermatic-bot kubermatic-bot merged commit 38805d4 into master Oct 9, 2019
@kubermatic-bot kubermatic-bot added this to the v2.12 milestone Oct 9, 2019
@kubermatic-bot kubermatic-bot deleted the controlplane-proxy branch October 9, 2019 19:29
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/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

configure proxy for control plane components in a seed
4 participants