Ask Your Question

Revision history [back]

Hi Bellantuono, I have solved the same problem by modify the swift/common/middleware/account_quotas.py

#

new_quota = request.headers.get('X-Account-Meta-Quota-Bytes')

Add by kevin start

eccp_roles = request.environ.get('HTTP_X_ROLES', '') if isinstance(eccp_roles, basestring): if (set(eccp_roles.split(',')) & set({'reseller','reseller_admin','ResellerAdmin'})): request.environ['reseller_request'] = True

Add by kevin end

if request.environ.get('reseller_request') is True: if new_quota and not new_quota.isdigit(): return HTTPBadRequest() return self.app

#

It seems that this part is not used for keystone.

Good luck

Hi Bellantuono, I have solved the same problem by modify the swift/common/middleware/account_quotas.py

#
##################################
  

new_quota = request.headers.get('X-Account-Meta-Quota-Bytes')

request.headers.get('X-Account-Meta-Quota-Bytes')

Add #Add by kevin start

start eccp_roles = request.environ.get('HTTP_X_ROLES', '') if isinstance(eccp_roles, basestring): if (set(eccp_roles.split(',')) & set({'reseller','reseller_admin','ResellerAdmin'})): request.environ['reseller_request'] = True

Add True #Add by kevin end

end

if request.environ.get('reseller_request') is True: if new_quota and not new_quota.isdigit(): return HTTPBadRequest() return self.app

#
self.app #################################

It seems that this part is not used for keystone.

Good luck