-
Notifications
You must be signed in to change notification settings - Fork 924
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
Updated Linode (Akamai Connected Cloud) support (including cloud-init) #1946
Conversation
Thanks for the contribution. When you get a chance, can you please add some test case for those changes? Thanks. |
It also seems like that it may be a good idea to rename the driver in the future (Akamai Connected Cloud)? We can still leave (deprecated) "linode" alias in place for the foreseeable future to make the change backward compatible. |
Acknowledged @Kami . I'll work on that. Regarding the name change, we haven't been directed to do that right now by the company, particularly as the API endpoint (api.linode.com) is unable to change for the forseeable future. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ran though all of the changes and tested them against the API and Metadata Service, everything worked like I expected it to 👍
725d2e0
to
d8add44
Compare
okie dokie @Kami I've pushed those tests. Take a 2nd look? |
NOTE: I do want to remove (or cleanup) this comment: d8add44#diff-e2e26eb0ef50c4cf2bf6b12658cd644d7ca1fe06cd2a3bc307d607149c83a2a4R976 Looking for feedback before I do that. |
# image=None, | ||
# name=None, | ||
# | ||
# Comments welcome on how backwards compatibility (if any) should work here. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's fine to leave it as-in and document this backward incompatible / breaking change in the upgrade notes file (https://github.com/apache/libcloud/blob/trunk/docs/upgrade_notes.rst), ideally with some concrete before / after code examples.
@mraygalaxy2 Thanks for adding the tests and addressing some very old API inconsistency in the I think it would be good to document that breaking API change in the upgrade notes file (d8add44#r127271125). Besides that, LGTM. |
@Kami Thank you, sir. I'll push a change right now to update that document. |
@@ -997,6 +1038,12 @@ def create_node( | |||
:keyword ex_private_ip: whether or not to request a private IP | |||
:type ex_private_ip: ``bool`` | |||
|
|||
:keyword ex_userdata: add cloud-config compatible userdata to be |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would actually be better to let user pass in a raw string and then we can take care of base64 encoding the string inside the method ourselves.
This way the method abstracts away this implementation detail from the end user (we already do a similar thing in a bunch of places).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Dorthu Would you like me to make that change? ^^^
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree that it would be more convenient for the library to handle the encoding, especially if there's precedent elsewhere in libcloud, as long as that behavior is featured prominently in the documentation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do! Thanks guys.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mraygalaxy2 Thanks. There is one more small thing which I thought I already commented on in the past (https://github.com/apache/libcloud/pull/1946/files#r1324941487), but maybe I forgot to :) |
1a8cbc9
to
bf2f681
Compare
1. cloud-init support is a new feature available in 2023. 2. The main entry point (create_node) had an arrangement of non-keyword parameters that were not consistent with other libcloud drivers. This has been fixed. 3. One remaining function (already available in the API) was exposed to also be consistent with other drivers.
bf2f681
to
5a9b157
Compare
OK, base64 changes complete. Also tell me if those those docs/upgrade_notes.rst and CHANGES.rst changes look ok. I'm happy to clean them up if there's a mistake. |
Thanks for addressing the review feedback. I made some small changes and merged it into trunk: |
Thank you so much, @Kami for the changes! Much appreciated. |
1. Merged: apache/libcloud#1946 (This will likely go into version 3.9.0, based on their current release schedule) 2. The use of metadata changed, so make cloudbench change accordingly.
1. Merged: apache/libcloud#1946 (This will likely go into version 3.9.0, based on their current release schedule) 2. The use of metadata changed, so make cloudbench change accordingly.
Updated Linode (Akamai Connected Cloud) support (including cloud-init)
Description
Status
Checklist (tick everything that applies)