Skip to content
This repository was archived by the owner on Sep 12, 2022. It is now read-only.

Commit 0ebcfc5

Browse files
authored
Merge pull request #611 from cdosborn/fix-quota-volume-update
Fix volume quota update
2 parents 86cc6d7 + 7cd6bca commit 0ebcfc5

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
2525
-->
2626

2727
## [Unreleased](https://github.com/cyverse/atmosphere/compare/v32-1...HEAD)
28+
### Fixed
29+
- Quota updates concerning volumes would silently fail ([#611](https://github.com/cyverse/atmosphere/pull/611))
30+
2831
## [v32-1](https://github.com/cyverse/atmosphere/compare/v32-0...v32-1) - 2018-04-17
2932
### Added
3033
- Support multiple hostnames for Atmosphere(1) server ([#602](https://github.com/cyverse/atmosphere/pull/602))

service/quota.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -209,10 +209,10 @@ def _set_volume_quota(user_quota, identity):
209209
username = identity.created_by.username
210210
logger.info("Updating quota for %s to %s" % (username, volume_values))
211211
driver = get_cached_driver(identity=identity)
212-
username = driver._connection._get_username()
213212
ad = get_account_driver(identity.provider)
214213
admin_driver = ad.admin_driver
215-
result = admin_driver._connection._cinder_update_quota(username, volume_values)
214+
tenant = ad.get_project(username)
215+
result = admin_driver._connection._cinder_update_quota(tenant.id, volume_values)
216216
logger.info("Updated quota for %s to %s" % (username, result))
217217
return result
218218

0 commit comments

Comments
 (0)