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

Add project-scoped API endpoints for OpenStack #5489

Merged

Conversation

embik
Copy link
Member

@embik embik commented Jan 2, 2023

What this PR does / why we need it:
This PR adds project-scoped API endpoints for fetching OpenStack information, which means that it is now possible to use presets with project limitations to provide credentials for the request.

Unfortunately, for two Openstack API endpoints I had to rename multi-tenancy headers (ProjectID -> OpenstackProjectID, Project -> OpenstackProject, etc) because it was shadowing the field for the KKP project IDs that is part of common.ProjectReq. That's not ideal, but I couldn't find a better solution. IMHO fields that include generic multi-tenancy terms like "project" should always be prefixed if they refer to a concept outside of the system that you are working on.

Which issue(s) this PR fixes:

Fixes #5130

What type of PR is this?
/kind feature
/kind api-change

Special notes for your reviewer:

Does this PR introduce a user-facing change? Then add your Release Note here:

Add API endpoints for OpenStack that allow using project-scoped Presets as credentials
ACTION REQUIRED:  Headers for API operations `listOpenstackServerGroups` and `listOpenstackSubnetPools` have been renamed from `Tenant`, `TenantID`, `Project`, `ProjectID` to `OpenstackTenant`, `OpenstackTenantID`, `OpenstackProject` and `OpenstackProjectID`, respectively

Documentation:

NONE

Signed-off-by: Marvin Beckers <marvin@kubermatic.com>
Signed-off-by: Marvin Beckers <marvin@kubermatic.com>
Signed-off-by: Marvin Beckers <marvin@kubermatic.com>
Signed-off-by: Marvin Beckers <marvin@kubermatic.com>
@kubermatic-bot kubermatic-bot added kind/feature Categorizes issue or PR as related to a new feature. release-note-action-required Denotes a PR that introduces potentially breaking changes that require user action. dco-signoff: yes Denotes that all commits in the pull request have the valid DCO signoff message. kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API do-not-merge/docs-needed Indicates that a PR should not merge because it's missing one of the documentation labels. sig/api Denotes a PR or issue as being assigned to SIG API. docs/none Denotes a PR that doesn't need documentation (changes). and removed do-not-merge/docs-needed Indicates that a PR should not merge because it's missing one of the documentation labels. labels Jan 2, 2023
@embik embik removed the request for review from ahmedwaleedmalik January 2, 2023 09:53
@kubermatic-bot kubermatic-bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jan 2, 2023
Signed-off-by: Marvin Beckers <marvin@kubermatic.com>
Signed-off-by: Marvin Beckers <marvin@kubermatic.com>
Copy link
Member

@ahmedwaleedmalik ahmedwaleedmalik left a comment

Choose a reason for hiding this comment

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

/approve

@kubermatic-bot kubermatic-bot added the lgtm Indicates that a PR is ready to be merged. label Jan 3, 2023
@kubermatic-bot
Copy link
Contributor

LGTM label has been added.

Git tree hash: cd53960253a9eb21cadcf83110c87349dbc0f0f4

@kubermatic-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ahmedwaleedmalik, embik

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 the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 3, 2023
@kubermatic-bot kubermatic-bot merged commit 4661a6c into kubermatic:main Jan 3, 2023
@embik embik deleted the project-scope-endpoints-openstack branch January 3, 2023 08:24
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. dco-signoff: yes Denotes that all commits in the pull request have the valid DCO signoff message. docs/none Denotes a PR that doesn't need documentation (changes). kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API kind/feature Categorizes issue or PR as related to a new feature. lgtm Indicates that a PR is ready to be merged. release-note-action-required Denotes a PR that introduces potentially breaking changes that require user action. sig/api Denotes a PR or issue as being assigned to SIG API. 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.

Add project-scoped API endpoints for OpenStack
3 participants