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

⚠️Move hardware profile code to the api module #1278

Merged
merged 1 commit into from May 31, 2023

Conversation

zaneb
Copy link
Member

@zaneb zaneb commented May 30, 2023

Since this code now defines how we map one API concept (the hardware profile string) to default values for other API concepts (root device hints), it is effectively part of the API definition. It is also not expected to exist in future API versions. The webhook for translating hosts between versions will need to access this code, so it will need to be inside the API module. Finally, similar to the hardwareutils module, this is useful in other contexts and moving it out of the main module eliminates extraneous external dependencies being dragged with it.

Since this code now defines how we map one API concept (the hardware
profile string) to default values for other API concepts (root device
hints), it is effectively part of the API definition. It is also not
expected to exist in future API versions. The webhook for translating
hosts between versions will need to access this code, so it will need to
be inside the API module. Finally, similar to the hardwareutils module,
this is useful in other contexts and moving it out of the main module
eliminates extraneous external dependencies being dragged with it.
@metal3-io-bot metal3-io-bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label May 30, 2023
@zaneb
Copy link
Member Author

zaneb commented May 30, 2023

/cc @dtantsur
/test-ubuntu-integration-main
/test-centos-e2e-integration-main

@dtantsur
Copy link
Member

/approve

@metal3-io-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dtantsur

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

@metal3-io-bot metal3-io-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 30, 2023
@zhouhao3
Copy link
Member

/lgtm

@metal3-io-bot metal3-io-bot added the lgtm Indicates that a PR is ready to be merged. label May 31, 2023
@metal3-io-bot metal3-io-bot merged commit 3b28ce0 into metal3-io:main May 31, 2023
10 checks passed
@smoshiur1237 smoshiur1237 changed the title Move hardware profile code to the api module ⚠️Move hardware profile code to the api module Aug 30, 2023
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. 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.

None yet

4 participants