cloud-provider-openstack icon indicating copy to clipboard operation
cloud-provider-openstack copied to clipboard

[occm] Add octavia listener xForwardedProto option

Open sungwon-ahn opened this issue 2 years ago • 13 comments

What this PR does / why we need it: Octavia provides the insert_header option as shown below. However, in OCCM, only X-Forwarded-For is available. As a result, we have implemented code to enable you to utilize this functionality in relation to XFP.

(You can find more information about this in the documentation)

Which issue this PR fixes(if applicable): fixes #

Special notes for reviewers:

Release note:

[openstack-cloud-controller-manager]  The x-forwarded-protocol of the Octavia listener is supported.

sungwon-ahn avatar Sep 17 '23 16:09 sungwon-ahn

CLA Signed

The committers listed above are authorized under a signed CLA.

  • :white_check_mark: login: sungwon-ahn / name: sungwon (03254a7cd92564bffdb936333b218157ef05ded5)

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Once this PR has been reviewed and has the lgtm label, please assign anguslees for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found 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

k8s-ci-robot avatar Sep 17 '23 16:09 k8s-ci-robot

Welcome @sungwon-ahn!

It looks like this is your first PR to kubernetes/cloud-provider-openstack 🎉. 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/cloud-provider-openstack 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. :smiley:

k8s-ci-robot avatar Sep 17 '23 16:09 k8s-ci-robot

Hi @sungwon-ahn. Thanks for your PR.

I'm waiting for a kubernetes 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 avatar Sep 17 '23 16:09 k8s-ci-robot

Can you describe your full end-to-end use case for this feature?

mdbooth avatar Sep 18 '23 09:09 mdbooth

There are more header insertions supported by Octavia. I think instead of implementing them one-by-one using annotations we may want to aim at creating a single annotation that will take a list of them and then OCCM will read that and populate InsertHeaders accordingly.

dulek avatar Sep 18 '23 13:09 dulek

Can you describe your full end-to-end use case for this feature?

Hi mdbooth! thx you for asking

I think it is necessary in the SSL offloading use case.

Octavia(HTTPS) < - > Nginx (HTTP) <-> Pod (HTTP)

You can enable the HTTPS protocol when using a load balancer of the load balancer type in Octavia.

In this use case, HTTPS requests passing through Octavia must be translated to HTTP and forwarded to the Pod (backend API server).

You can identify the protocol being used in this request by checking the 'x-forwarded-protocol' header.

sungwon-ahn avatar Sep 19 '23 14:09 sungwon-ahn

Can you describe your full end-to-end use case for this feature?

Hi mdbooth! thx you for asking

I think it is necessary in the SSL offloading use case.

Octavia(HTTPS) < - > Nginx (HTTP) <-> Pod (HTTP)

You can enable the HTTPS protocol when using a load balancer of the load balancer type in Octavia.

In this use case, HTTPS requests passing through Octavia must be translated to HTTP and forwarded to the Pod (backend API server).

You can identify the protocol being used in this request by checking the 'x-forwarded-protocol' header.

Would you be able to use the Octavia ingress controller instead for this use case? I worry in general about continuing to add annotations to service objects.

mdbooth avatar Sep 25 '23 09:09 mdbooth

/ok-to-test

jichenjc avatar Sep 26 '23 10:09 jichenjc

PR needs rebase.

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 avatar Oct 01 '23 18:10 k8s-ci-robot

@sungwon-ahn: 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-cloud-provider-openstack-check 03254a7cd92564bffdb936333b218157ef05ded5 link true /test pull-cloud-provider-openstack-check
openstack-cloud-controller-manager-e2e-test 03254a7cd92564bffdb936333b218157ef05ded5 link true /test openstack-cloud-controller-manager-e2e-test
openstack-cloud-csi-manila-e2e-test 03254a7cd92564bffdb936333b218157ef05ded5 link true /test openstack-cloud-csi-manila-e2e-test
openstack-cloud-csi-cinder-e2e-test 03254a7cd92564bffdb936333b218157ef05ded5 link true /test openstack-cloud-csi-cinder-e2e-test
openstack-cloud-csi-manila-sanity-test 03254a7cd92564bffdb936333b218157ef05ded5 link true /test openstack-cloud-csi-manila-sanity-test
openstack-cloud-csi-cinder-sanity-test 03254a7cd92564bffdb936333b218157ef05ded5 link true /test openstack-cloud-csi-cinder-sanity-test
openstack-cloud-keystone-authentication-authorization-test 03254a7cd92564bffdb936333b218157ef05ded5 link true /test openstack-cloud-keystone-authentication-authorization-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/test-infra repository. I understand the commands that are listed here.

k8s-ci-robot avatar Nov 01 '23 03:11 k8s-ci-robot

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-triage-robot avatar Jan 30 '24 04:01 k8s-triage-robot

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-triage-robot avatar Feb 29 '24 04:02 k8s-triage-robot

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-triage-robot avatar Mar 30 '24 04:03 k8s-triage-robot

@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/test-infra repository.

k8s-ci-robot avatar Mar 30 '24 04:03 k8s-ci-robot