Skip to main content

Advanced command line tool for QingStor.

Project description

qsctl is intended to be an advanced command line tool for QingStor, it provides powerful unix-like commands to let you manage QingStor resources just like files on local machine. Unix-like commands contains: cp, ls, mb, mv, rm, rb, and sync. All of them support batch processing.

Installation

virtualenv:

$ pip install qsctl

System-Wide:

$ sudo pip install qsctl

On Windows systems, run it in a command-prompt window with administrator privileges, and leave out sudo.

Getting Started

To use qsctl, there must be a configuration file , for example:

access_key_id: 'ACCESS_KEY_ID_EXAMPLE'
secret_access_key: 'SECRET_ACCESS_KEY_EXAMPLE'

The configuration file is ~/.qingstor/config.yaml by default, it also can be specified by the option -c /path/to/config.

You can also config other option like host , port and so on, just add lines below into configuration file, for example:

host: 'qingstor.com'
port: 443
protocol: 'https'
connection_retries: 3
# Valid levels are 'debug', 'info', 'warn', 'error', and 'fatal'.
log_level: 'debug'

Available Commands

Commands supported by qsctl are listed below:

ls

List QingStor keys under a prefix or all QingStor buckets.

cp

Copy local file(s) to QingStor or QingStor key(s) to local.

mb

Create a QingStor bucket.

rb

Delete an empty QingStor bucket or forcibly delete nonempty QingStor bucket.

mv

Move local file(s) to QingStor or QingStor key(s) to local.

rm

Delete a QingStor key or keys under a prefix.

sync

Sync between local directory and QingStor prefix.

Examples

List keys in bucket <mybucket> by running:

$ qsctl ls qs://mybucket
Directory                          test/
2016-04-03 11:16:04     4 Bytes    test1.txt
2016-04-03 11:16:04     4 Bytes    test2.txt

Sync from QingStor prefix to local directory:

$ qsctl sync qs://mybucket3/test/ test/
File 'test/README.md' written
File 'test/commands.py' written

See the detailed usage and more examples with ‘qsctl help’ or ‘qsctl <command> help’.

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

qsctl-1.2.0.tar.gz (52.3 kB view details)

Uploaded Source

Built Distribution

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

qsctl-1.2.0-py2.py3-none-any.whl (76.6 kB view details)

Uploaded Python 2Python 3

File details

Details for the file qsctl-1.2.0.tar.gz.

File metadata

  • Download URL: qsctl-1.2.0.tar.gz
  • Upload date:
  • Size: 52.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for qsctl-1.2.0.tar.gz
Algorithm Hash digest
SHA256 15242033228b92f5187bfcf3487b6c6c41bfc507435ea309a3c0e30e9fe17461
MD5 94eda72333bf1311b60a89f6c3781052
BLAKE2b-256 578fa88dbacf1ac9e638c67a88a4a27d0b8529eb0d33a2ab85fb6668b40f5917

See more details on using hashes here.

File details

Details for the file qsctl-1.2.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for qsctl-1.2.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 7dfca5981ce568ec5f888edfce75d25e766456d52a165e1732399236a34f1f21
MD5 27c5b7beee92114d44303214416243dd
BLAKE2b-256 8aa21329b0e69bf5baeace249019ace7485d5f2c17cff3d83d1e5a434026f9fc

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