Run pipelines similar to github actions
Project description
kaxi
Run pipelines similar to github actions
Installation
pip install kaxi
Usage
You can run a pipeline by running the following command:
kaxi <pipeline_file>.yaml
Or you can programmatically run a pipeline by running the following command:
from kaxi import Runner
runner = Runner(your_pipeline)
runner.execute()
Pipeline file
A pipeline file is a yaml file that contains a list of steps to execute. Each step is a dictionary with the following keys:
uses
: The callable to execute (e.g.pandas.read_csv
)name
(optional): The name of the stepwith
(optional): A dictionary of arguments to pass to the callable
If you want to use arguments without the respective name, you can use the args
key inside the with
dictionary.
Example
verbose: true
steps:
- uses: os.path.isfile
name: file_exists
with:
path: example.yaml
- uses: kaxi.log.info
with:
args:
- ${file_exists}
Environment variables
You can use environment variables in your pipeline file by using the ${ENV_VAR}
syntax.
To define environment variables, you can set them inside the enviroment
key:
environment:
ENV_VAR: value
Another way to use environment variables is to use the ouput of a step as an environment variable, this can be done by using the name
of the step inside the ${}
syntax:
steps:
- uses: os.path.isfile
name: file_exists
with:
path: example.yaml
- uses: kaxi.log.info
with:
args:
- ${file_exists}
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
File details
Details for the file kaxi-0.1.1.tar.gz
.
File metadata
- Download URL: kaxi-0.1.1.tar.gz
- Upload date:
- Size: 4.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.2 CPython/3.11.4 Linux/5.15.0-1039-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 70bd31cba6aff608592c9a62ab1a96911a9f84210fd12ad70a9db0fae69a760f |
|
MD5 | 4e0cbc703465dbd2fa2cd22c3706e057 |
|
BLAKE2b-256 | 659f038f6e5f1c3497faddd083be72791f2c00a8f3775a77378924854e0d3ee4 |
File details
Details for the file kaxi-0.1.1-py3-none-any.whl
.
File metadata
- Download URL: kaxi-0.1.1-py3-none-any.whl
- Upload date:
- Size: 5.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.2 CPython/3.11.4 Linux/5.15.0-1039-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0992e19046599f9d9773723f5c7456b9f5afad6fe5c23316914cb029ca98c694 |
|
MD5 | d524b608b169380b54c3136e9ade22b2 |
|
BLAKE2b-256 | 379537502ded2e001f4cdf45e83cda101038687d76a81b1f983dbb9ff75554b8 |