A straight forward tool to get information from docker command line and try to parse into json format as far as possible.
Project description
Docker-cli
A straight forward tool to get information from docker command line and try to parse into json format as far as possible.
Why not docker api?
- The api schema might change and response data might change so often.
- Docker-cli uses docker cli to get response and try to format them into json format
Installation
pip install docker-cli
Main methods
is_docker_set()to verify docker installation and availability
docker_cli.is_docker_set()
- To run docker commands
Request: docker_cli.docker("ps")
Response Structure:
DockerResponse(command='docker ps', status='SUCCESS', type='JSON', data=[<JSON Data>])
- To run docker commands
Request: docker_cli.docker_compose("up -d")
Response Structure:
Similar as that of docker commands
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
docker-cli-1.0.2.tar.gz
(2.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file docker-cli-1.0.2.tar.gz.
File metadata
- Download URL: docker-cli-1.0.2.tar.gz
- Upload date:
- Size: 2.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.6 CPython/3.8.5 Linux/5.8.0-55-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d67718574f4cde543192aeddcc7e23cf143daae17b4dc3862335090ea26556ec
|
|
| MD5 |
13cafac66c7a1b10515d89665960e5d5
|
|
| BLAKE2b-256 |
ce88d0b6e3b2a57b4f74e608c9509333b96fe1d1bae067ff7b7c37ba04263ef6
|
File details
Details for the file docker_cli-1.0.2-py3-none-any.whl.
File metadata
- Download URL: docker_cli-1.0.2-py3-none-any.whl
- Upload date:
- Size: 2.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.6 CPython/3.8.5 Linux/5.8.0-55-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
de43229f4d565773bfa52ef566bd76145a57da12650eedd406b34b1620e72228
|
|
| MD5 |
52b81270d53882883068f9d45379ff73
|
|
| BLAKE2b-256 |
303e5f7a34ee9c35e7bbe366371237234b92a53c3537ce04bb16ede8b0b17c7a
|