SIP Docker Swarm client library.
Project description
# Docker Swarm Client API
## Introduction
The SIP Execution Framework provides a Docker Client Python API to run
docker services by various Execution Control Service components.
The client library is written as a of Python modules which are structured as a
set of higher level modules use by various Execution Control Services.
The client lets you run docker commands from within Python - create services,
delete services, manage nodes etc
## Quick-start
Install with:
```bash
pip3 install -U skasip-docker-swarm
```
Example usage:
```python
from sip_docker_swarm import DockerClient
DC = DockerClient()
```
## Testing
Linting and unit test are run automatically by SIP CI/CD system but can also be
run manually from the docker_api code directory with:
```bash
pytest --pylint --docstyle --codestyle -s -v --pylint-rcfile=../../../.pylintrc .
```
or run the following command from the top level directory
```bash
./tools/run_tests.sh sip/execution_control/docker_api/sip_docker_swarm
```
## TODO
* Need to add exception into the functions
* Add Log to the script
* depends_on is not enabled -> Need to look into this
* Need to setup the environment variables
* Unit test for update_node function
* Figure out how to validate compose files
* While it is useful to test that service exists, it mighe be even better to test
that the service is running as well
## Introduction
The SIP Execution Framework provides a Docker Client Python API to run
docker services by various Execution Control Service components.
The client library is written as a of Python modules which are structured as a
set of higher level modules use by various Execution Control Services.
The client lets you run docker commands from within Python - create services,
delete services, manage nodes etc
## Quick-start
Install with:
```bash
pip3 install -U skasip-docker-swarm
```
Example usage:
```python
from sip_docker_swarm import DockerClient
DC = DockerClient()
```
## Testing
Linting and unit test are run automatically by SIP CI/CD system but can also be
run manually from the docker_api code directory with:
```bash
pytest --pylint --docstyle --codestyle -s -v --pylint-rcfile=../../../.pylintrc .
```
or run the following command from the top level directory
```bash
./tools/run_tests.sh sip/execution_control/docker_api/sip_docker_swarm
```
## TODO
* Need to add exception into the functions
* Add Log to the script
* depends_on is not enabled -> Need to look into this
* Need to setup the environment variables
* Unit test for update_node function
* Figure out how to validate compose files
* While it is useful to test that service exists, it mighe be even better to test
that the service is running as well
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
Built Distribution
Close
Hashes for skasip-docker_swarm-1.0.7.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 917d12c80857678e3f322bad9136be9399d44275ac4397ddb55917982a727831 |
|
MD5 | 67b5d0b6bf07d055d574ade55ec97605 |
|
BLAKE2b-256 | 8a980e17a89ea3d9df0a8485cd2edb0486fa7c9fddda0f829f2bd0a304a01738 |
Close
Hashes for skasip_docker_swarm-1.0.7-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9d90d04f1765bbefe9b2f7e8bf90a2d7d374b91d6ef5ffc5f8b3dc3e8a0d5a75 |
|
MD5 | 34d1927f283ea956370f2e319c62dcd1 |
|
BLAKE2b-256 | c17244593699c02adde3c507fd116e0accace94a5bc3d05766e59a53a7538f30 |