Template project for Chaos Toolkit extensions
Project description
Chaos Toolkit Extension Template
Chaos Toolkit extension to manage lueur network proxy.
Install
This package requires Python 3.9+
To be used from your experiment, this package must be installed in the Python environment where chaostoolkit already lives.
pip install chaostoolkit-lueur
Usage
{
"title": "Increase latency by 150ms",
"description": "n/a",
"method": [
{
"type": "action",
"name": "run lueur proxy with a normal distribution latency",
"provider": {
"type": "python",
"module": "chaoslueur.actions",
"func": "run_proxy",
"arguments": {
"proxy_args": "--with-latency --latency-mean 300 --latency-stddev 50 --upstream '*'"
}
},
"background": true
},
{
"type": "action",
"name": "query remote upstream",
"provider": {
"type": "process",
"path": "curl",
"arguments": "-I -o /dev/null -s -w \"Connected IP: %{remote_ip}\nTotal time: %{time_total}s\" -x http://localhost:8080 https://www.google.com"
}
},
{
"type": "action",
"name": "stop proxy",
"provider": {
"type": "python",
"module": "chaoslueur.actions",
"func": "stop_proxy"
}
}
]
}
That's it!
Please explore the code to see existing actions.
Test
To run the tests for the project execute the following:
pdm run test
Formatting and Linting
We use ruff
to both lint and format this repositories code.
Before raising a Pull Request, we recommend you run formatting against your code with:
pdm run format
This will automatically format any code that doesn't adhere to the formatting standards.
As some things are not picked up by the formatting, we also recommend you run:
pdm run lint
To ensure that any unused import statements/strings that are too long, etc. are also picked up.
Contribute
If you wish to contribute more functions to this package, you are more than welcome to do so. Please, fork this project, make your changes following the usual code style, sprinkling with tests and submit a PR for review.
To contribute to this project, you will also need to install pdm.
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 chaostoolkit_lueur-0.13.3.tar.gz
.
File metadata
- Download URL: chaostoolkit_lueur-0.13.3.tar.gz
- Upload date:
- Size: 8.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
4fc9c12629c429fabc166badba259d1683a15c8885d8c385d28913014cc3eda2
|
|
MD5 |
506475d7b4c44f536270f70a37e2146c
|
|
BLAKE2b-256 |
a96992d051df6a2e94ea7830708f756f7b99eddbea3c426bf793747b7b2ab804
|
Provenance
The following attestation bundles were made for chaostoolkit_lueur-0.13.3.tar.gz
:
Publisher:
release.yaml
on chaostoolkit-incubator/chaostoolkit-lueur
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1
-
Predicate type:
https://docs.pypi.org/attestations/publish/v1
-
Subject name:
chaostoolkit_lueur-0.13.3.tar.gz
-
Subject digest:
4fc9c12629c429fabc166badba259d1683a15c8885d8c385d28913014cc3eda2
- Sigstore transparency entry: 189403156
- Sigstore integration time:
-
Permalink:
chaostoolkit-incubator/chaostoolkit-lueur@6ad90b74156149878d242f00466581ae20f2335e
-
Branch / Tag:
refs/tags/0.13.3
- Owner: https://github.com/chaostoolkit-incubator
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com
-
Runner Environment:
github-hosted
-
Publication workflow:
release.yaml@6ad90b74156149878d242f00466581ae20f2335e
-
Trigger Event:
push
-
Statement type:
File details
Details for the file chaostoolkit_lueur-0.13.3-py3-none-any.whl
.
File metadata
- Download URL: chaostoolkit_lueur-0.13.3-py3-none-any.whl
- Upload date:
- Size: 9.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
135d3d2ac881e07440eaf25222ca71895f2a3c7dc5841388bb6f0e86069d6ec8
|
|
MD5 |
0c213fd5ea6d64cff15b248edf774598
|
|
BLAKE2b-256 |
fff245d22861aa95ed09b70a6f420a49367189ac32ca4615dd277266dee98625
|
Provenance
The following attestation bundles were made for chaostoolkit_lueur-0.13.3-py3-none-any.whl
:
Publisher:
release.yaml
on chaostoolkit-incubator/chaostoolkit-lueur
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1
-
Predicate type:
https://docs.pypi.org/attestations/publish/v1
-
Subject name:
chaostoolkit_lueur-0.13.3-py3-none-any.whl
-
Subject digest:
135d3d2ac881e07440eaf25222ca71895f2a3c7dc5841388bb6f0e86069d6ec8
- Sigstore transparency entry: 189403158
- Sigstore integration time:
-
Permalink:
chaostoolkit-incubator/chaostoolkit-lueur@6ad90b74156149878d242f00466581ae20f2335e
-
Branch / Tag:
refs/tags/0.13.3
- Owner: https://github.com/chaostoolkit-incubator
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com
-
Runner Environment:
github-hosted
-
Publication workflow:
release.yaml@6ad90b74156149878d242f00466581ae20f2335e
-
Trigger Event:
push
-
Statement type: