chaos-proxy

module
v0.0.0-...-fe16607 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 19, 2024 License: MIT

README ΒΆ

chaos-proxy

A proxy for testing out the behaviour of network applications with bandwidth limitations, latency and packet loss.

GoActions GoDoc Go Report Card latest version

πŸ“¦ Requirements

  • 🐳 Docker
  • πŸ™ docker-compose
  • Golang(>=1.11)
  • Make

🐳 Docker

Running the proxy server in docker requires to build the docker image. Just navigate to ./deployments/docker and run docker-compose build.

In order to configure the container you can use a config file, which will look like:

  • Customize the ./configs/config.yml
  • Run docker run -p "8080:8080" -v "${PWD}/config.yml:/config.yml" chaos-proxy in the same directory with the config.yml

πŸ”§ Usage

  • Customize the ./configs/config.yml
  • Run make run in order to start the server
  • When running the server the running proxy connections can be configured on the fly via an api. The api runs on a configured port under /api. For the documentation take a look at ./api/swagger.yml or open the /doc route when running in development mode(log_level set to debug).

🀝 Contributing

If you are missing features or find some annoying bugs please feel free to submit an issue or a bugfix within a pull request :)

🚧 TODO

  • implement udp handler

πŸ“ License

Β© 2019 Daniel Jankowski

This project is licensed under the MIT license.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Directories ΒΆ

Path Synopsis
cmd
internal
middleware
Package middleware Provides custom middlewares for the application.
Package middleware Provides custom middlewares for the application.
router
Package router Implement a small webserver offering an api to control and setup different proxy connections.
Package router Implement a small webserver offering an api to control and setup different proxy connections.
pkg
config
Package config Parse and create config objects.
Package config Parse and create config objects.
metrics
Package metrics Provide a simple intuitive use of prometheus metrics
Package metrics Provide a simple intuitive use of prometheus metrics
proxy
Package proxy Implement proxy components for different protocols.
Package proxy Implement proxy components for different protocols.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL