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

driver: check volume limit #73

Merged
merged 4 commits into from
Sep 5, 2018
Merged

driver: check volume limit #73

merged 4 commits into from
Sep 5, 2018

Conversation

fatih
Copy link
Contributor

@fatih fatih commented Aug 31, 2018

fixes #31

This includes digitalocean/godo#177 which we
need to implement volume limit check

Updated with the command:

```
dep ensure -update github.com/digitalocean/godo
```
}

// administrative accounts might have zero length limits, make sure to not check them
if account.VolumeLimit == 0 {
Copy link

Choose a reason for hiding this comment

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

👑

return nil // hail to the king!
}

volumes, _, err := d.doClient.Storage.ListVolumes(ctx, &godo.ListVolumeParams{
Copy link

Choose a reason for hiding this comment

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

🎗 this is listing volumes by region but the received limit is for all regions.
meaning: this is a best-effort check and won't ever hit in case the user has at least 1 volume in a different region.

the proper fix is for us ( DigitalOcean ) to expose limits per region. it is in the works but no ETA.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks Lucas, good to know. I added a note to the source code so it's aware to the reader as well: 445ec7a

@lxfontes
Copy link

lxfontes commented Sep 4, 2018

@fatih fatih merged commit fc52322 into master Sep 5, 2018
@fatih fatih deleted the check-volume-limit branch September 5, 2018 07:20
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.

Feature Improvement : Verify volume_limit when making a provisioning call to DO api
2 participants