TPT-4527: Implemented changes for SLADE and CLEO projects#665
TPT-4527: Implemented changes for SLADE and CLEO projects#665ezilber-akamai wants to merge 4 commits intolinode:proj/slade-cleofrom
Conversation
2acd3aa to
a29b93a
Compare
There was a problem hiding this comment.
Pull request overview
This PR updates the Linode create/rebuild/disk-create flows to support SLADE/CLEO requirements by adding kernel and boot_size to instance creation and changing how root_pass is handled when SSH keys are provided.
Changes:
- Add
kernelandboot_sizefields toLinodeGroup.instance_create. - Change
instance_create,Instance.rebuild, andInstance.disk_createto require at least one ofroot_passorauthorized_keys, and stop returning generated passwords. - Update unit tests to pass explicit
root_passand to assert the new return values.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 10 comments.
Show a summary per file
| File | Description |
|---|---|
linode_api4/groups/linode.py |
Updates instance_create signature, validation, request payload, and return type; adds kernel/boot_size. |
linode_api4/objects/linode.py |
Updates disk_create and rebuild credential validation and return behavior. |
test/unit/objects/linode_test.py |
Updates object-level unit tests for rebuild and disk_create new return values and request bodies. |
test/unit/linode_client_test.py |
Updates client unit tests for instance_create to include explicit root_pass and assert payload. |
test/unit/groups/linode_test.py |
Updates/extends group-level unit tests, including new coverage for kernel/boot_size. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
a29b93a to
71544fc
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
test/unit/linode_client_test.py
Outdated
| "us-east-1a", | ||
| image="linode/debian9", | ||
| root_pass="aComplex@Password123", | ||
| boot_size=5000, |
There was a problem hiding this comment.
boot_size should be greater than 8192 according to the API spec. Although this is an unit test, let's make it right.
|
Is it accessible in prod API yet? If so, can we have some integration tests as well? |
No API access yet I believe. We have a separate ticket for integration tests once the test plan is complete and we have API access. |
📝 Description
Added new kernel and boot_size fields to Linode Create options. Also made
root_passoptional whenimageis provided (ifauthorized_keysis provided instead) for Linode creation and rebulding, and Linode Disk creation.✔️ How to Test
make test-unit