Installation
Installing Cowait on your local machine.
Requirements
Cowait is a python library that packages and runs tasks in Docker containers, both locally and on Kubernetes. The base requirements are:
- Python 3.6+
- Docker
Installation
Cowait is available on Pypi, you can install it with pip
:
python -m pip install cowait
We recommend installing in a virtual environment (virtualenv/venv) or using a python package manager such as Poetry or Pipenv.
To quickly get started with Cowait, we provide a slim Docker image (~59 MB) that includes the Cowait library. It is based on this Dockerfile. Pull the latest image.
docker pull cowait/task
You are now ready for your first steps.
Development
If you would like to contribute to Cowait, you may install Cowait from source:
- Clone the repository
git clone git@github.com:backtick-se/cowait.git
cd cowait
- It is recommended to first setup a virtual env of your choice. A
pyproject.toml
for Poetry is provided for your convenience in the root of the repository. - Install the library using pip's editable mode.
python -m pip install -e .
- Make changes to the library. Note that changes to the
cowait/
directory require a rebuild of the base image. You can do this with the provided helper script in the root of the repository:
./build.sh
- Note that tasks you use to test your new feature or bug-fix will have to be rebuilt with
cowait build
for the changes to take effect.