in files/default/rgw_webservice.py [0:0]
def user_quota_enable(self, user, region=None, zone=None, zone_region_prefix="client.radosgw"):
if region is not None and zone is not None:
cmd = ["sudo", "/bin/radosgw-admin", "quota", "enable", "--conf", "/etc/ceph/ceph.conf", "--uid", "%s" % user, "--quota-scope", "user"]
else:
cmd = ["/usr/bin/radosgw-admin", "quota", "enable", "--conf", "/etc/ceph/ceph.conf", "--uid", "%s" % user, "--quota-scope", "user"]
if region is not None and zone is not None:
cmd.append("-n")
# NB: This should match '[client.radosgw...]' or something similar found in ceph.conf for the RGW section
cmd.append("%s.%s-%s" % (zone_region_prefix, region, zone))
return call(cmd)