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

Switch to Linode API v4 #9

Merged
merged 28 commits into from
Aug 1, 2022
Merged

Conversation

testeddoughnut
Copy link
Contributor

Howdy! This is a major update to switch this project to use Linode API v4. As well, it modernizes the code to follow patterns in other upstream kitchen drivers, including switching to chefstyle instead of using rubocop directly and bumping all dependencies. A more comprehensive list of changes follows:

  • Switch from fog to fog-linode to switch to Linode API v4.
  • Add API retry support to retry calls on timeouts or rate-limits.
  • Bumped all dependencies to what the upstream plugins are using.
  • Switch to using chefstyle so we don't have to managed our own rubocop config.
  • Added support for most APIv4 options for Linode Create.
  • Dropped some options (kernel, for example) that aren't supported on the create call.
  • Added additional environment variable support for options where it made sense.
  • Removed all the API calls to validate image, region, kernel etc since the create call does that for us.
  • Added better error reporting for when the create call runs into trouble.
  • Added checks around label generation to avoid creating an instance with a duplicate label.
  • Improved support for the post-build steps to set hostname and disable password login.
    • It now works for all base images that Linode offers, including the less popular ones.
    • It also now disables password login through SSH config instead of just locking the account.
  • Added a .kitchen.yml file to test all base images. This is not added to the CI at this time.
  • Updated all tests to be more comprehensive and to simulate the API calls with webmock.
  • Updated README to cover all the new options and features.

stvnjacobs and others added 28 commits April 16, 2021 23:28
There were type errors when providing the object. This is a change from
the previous fog linode provider.
This just wraps the API calls in a retry when the API returns a
408. By default it retries 3 times, that can be adjusted using
the `api_retries` config option.

Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Now the code will check if another server is already using the
label is wants, and if so it'll pick a different random suffix.

Added retry support if we do end up with a non-unique label
on server create.

Added better error handling on deletes so a 404 doesn't make
it nervous.

Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Retry API requests on timeouts (HTTP status 408)
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
Signed-off-by: M. David Bennett <mdavidbennett@syntheticworks.com>
@testeddoughnut
Copy link
Contributor Author

@ssplatt is this project still being maintained?

@ssplatt ssplatt merged commit 68f5e9e into ssplatt:master Aug 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants