https://github.com/josephwoodward/chaosproxy
A simple means of introducing chaos into your infrastructure for Windows, Mac and Linux.
https://github.com/josephwoodward/chaosproxy
chaos-engineering go golang
Last synced: 11 months ago
JSON representation
A simple means of introducing chaos into your infrastructure for Windows, Mac and Linux.
- Host: GitHub
- URL: https://github.com/josephwoodward/chaosproxy
- Owner: josephwoodward
- Created: 2017-05-23T09:52:59.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-07-03T14:12:09.000Z (almost 9 years ago)
- Last Synced: 2025-06-16T10:55:10.589Z (about 1 year ago)
- Topics: chaos-engineering, go, golang
- Language: Go
- Homepage:
- Size: 32.2 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Chaos Proxy
A controlled means of introducing chaos into your infrastructure for Windows, Mac and Linux.
Features:
- Target HTTP endpoints (including DynamoDB, S3, or HTTP based APIs) via hostname or path regular expression
- Ability to target only a proportion of requests (ie: 30% of requests will timeout)
- Force latency or simulate throttling on HTTP based APIs
- Specify response status code
## How to use it:
### Step 1: Create a config file
```yml
# config.yml
config:
enabled: true # optional
port: 8082
endpoints:
- host: (\S+)-consumer-iapi-(\S+)$ # required
url: \/consumer\/optinflow(\/?)$ # required
delay: 5000 # optional - default is 0
range: 50 # optional - default is 100
responseStatusCode: 504 # optional - default is 200
- host: (\S+)-public-iapi-(\S+)$
url: \/authorize\/providers\?tenant=(es|ie|it)$
delay: 5000
range: 30
- host: www.bbc.co.uk$
url: \/weather(\/?)$
delay: 5000
range: 100
responseStatusCode: 504
- host: ^dynamodb.(\S+)$
url: ^(\S+)$
delay: 5000
range: 100
```
### Step 2: Run it
```
$ chaos_proxy.exe -logtostderr=true
```
Note: Use `$ chaos_proxy.exe -h` to view all CLI options.
### Step 3: Proxy requests
**IIS:**
Add this to your web.config:
```
```
You may need to restart IIS `iisreset /stop` then `iisreset /start`
**Firefox:**
In Firefox go to `Options > Advanced > Network > Connection Settings`
## Compatibility:
- Mac
- Windows
- Linux
## Coming soon
- Ability to target requests based on HTTP request methods (GET, POST etc)
- HTTP endpoint allowing you to post behaviour changes to Chaos Proxy
- Dashboard allowing you to visualise traffic flowing through proxy and matching behaviours
- Set behaviour rules to activate/deactivate between certain dates and times
- Watch for config file changes
- Tests!