Skip to main content

Python Rados Gateway Admin API

Project description

rgwadmin

Documentation Status

rgwadmin is a Python library to access the Ceph Object Storage Admin API.

http://docs.ceph.com/docs/master/radosgw/adminops/

API Example Usage

from rgwadmin import RGWAdmin

rgw = RGWAdmin(access_key='XXX', secret_key='XXX', server='obj.example.com')
rgw.create_user(
    uid='liam',
    display_name='Liam Monahan',
    email='liam@umiacs.umd.edu',
    user_caps='usage=read, write; users=read',
    max_buckets=1000)
rgw.set_user_quota(
    uid='liam',
    quota_type='user',
    max_size_kb=1024*1024,
    enabled=True)
rgw.remove_user(uid='liam', purge_data=True)

User Example Usage

from rgwadmin import RGWAdmin, RGWUser

RGWAdmin.connect(access_key='XXX', secret_key='XXX', server='obj.example.com')
u = RGWUser.create(user_id='test', display_name='Test User')
u.user_quota.size = 1024 * 1024  # in bytes
u.user_quota.enabled = True
u.save()
u.delete()

Requirements

rgwadmin requires the following Python packages:

Additionally, you need to have a Ceph Object Storage instance with a user that has appropriate caps (capabilities) on the parts of the API that you want to access. See the Ceph Object Storage page for more information.

Version 2.3.1 was the last to support Python 2. As of version 2.4.0 we support using V4 signing for requests to the Ceph RGW Admin server only.

Compatibility

rgwadmin implements all documented Admin API operations or recent versions of Ceph. We also implement some of the undocumented ones, too...

Installation

pip install rgwadmin

License

rgwadmin - a Python interface to the Rados Gateway Admin API
Copyright (C) 2015  UMIACS

This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA

Email:
    github@umiacs.umd.edu

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rgwadmin-2.4.5.tar.gz (30.6 kB view details)

Uploaded Source

Built Distribution

rgwadmin-2.4.5-py3-none-any.whl (21.0 kB view details)

Uploaded Python 3

File details

Details for the file rgwadmin-2.4.5.tar.gz.

File metadata

  • Download URL: rgwadmin-2.4.5.tar.gz
  • Upload date:
  • Size: 30.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.17

File hashes

Hashes for rgwadmin-2.4.5.tar.gz
Algorithm Hash digest
SHA256 ae0c4e4345722516fca6f99e6bbe88597735d235d81449a240a0702874352b34
MD5 c6e64c83871cc7024dae9ebb8773fd0d
BLAKE2b-256 932c5c0673aec781e9b87bd9f9e661e9402589b007f1838daba879c954db4881

See more details on using hashes here.

File details

Details for the file rgwadmin-2.4.5-py3-none-any.whl.

File metadata

  • Download URL: rgwadmin-2.4.5-py3-none-any.whl
  • Upload date:
  • Size: 21.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.17

File hashes

Hashes for rgwadmin-2.4.5-py3-none-any.whl
Algorithm Hash digest
SHA256 7e5328198a2163f6d486e3957cc967ab7dc2548848fcfb9c8fd99fa64ad5e262
MD5 55c25ab9294d827787c4fd205a90f3c8
BLAKE2b-256 9d4e15804beb0bbc0aa290b19d9e25dbe6d50d2f730528539c8a40d327c30e68

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page