echoer

command module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 28, 2019 License: MIT Imports: 5 Imported by: 0

README

echoer

Actions Status image metadata

Simple http server which echoes HTTP requests.

Usage

Automatically built image.

docker run -p 80:80 kamko/echoer

Configuration

via env vars (shown values are defaults)

PORT=80
BODY_AS_STRING=TRUE

Example

{
  "body": "{\n\t\"value1\": \"ABC\"\n}",
  "headers": {
    "Accept": "*/*",
    "Content-Length": "20",
    "User-Agent": "insomnia/7.0.6"
  },
  "uri": "/?param1=1&param2=2"
}

When BODY_AS_STRING is set to false the body is returned as base64 string.

{
  "body": "ewoJInZhbHVlMSI6ICJBQkMiCn0=",
  "headers": {
    "Accept": "*/*",
    "Content-Length": "20",
    "User-Agent": "insomnia/7.0.6"
  },
  "uri": "/?param1=1&param2=2"
}

Build with

  • go 1.13.5 with Echo

License

MIT

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

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