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.1.tar.gz (30.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rgwadmin-2.4.1-py3-none-any.whl (20.9 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for rgwadmin-2.4.1.tar.gz
Algorithm Hash digest
SHA256 2fbae3ebc3659005dfccc28b49a0add8468d7ae738cafe774747c91b4b038d66
MD5 e96ef47a54eb7008251a52b981a4e389
BLAKE2b-256 c31be51ce335c89a0432947437b5e3cc0cec610f26712e6316c4a32494f76167

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for rgwadmin-2.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 9c4b9dff69fea57a17939a0c7a72bc231cf4d525c807cfb5c2c80ca027be321d
MD5 75974ae0802256c6189a1db0096ae610
BLAKE2b-256 d9eeed41277d5dac0be705c13b2bf6224ab69c1720e6f18162d862125e28c48e

See more details on using hashes here.

Supported by

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