Skip to content

🧚 A simple REST Service that echoes back request send to it as well as provide some testing functionality.

License

Notifications You must be signed in to change notification settings

cloudkats/hello-world-rest

Repository files navigation

Hello World REST Service

Simple REST Service that echos some requests back, has health and version checks. This service runs inside a container so there is almost no overhead in getting started.



Contents

What is this sevice good for?

  • Easy test reverse proxy routes and paths.
  • Use this service as a dummy to see if request reach your service correctly.
  • Use it to test load balancers by peeking at the out and see the host/ip.
  • Use it for Hello World demo projects that require some basic Rest functionality.

Endpoints

/version
/status
/env
/env/:pattern
/echo
/echo/headers

Docker Image

Name Badges Version
Hello World App docker.build-push

Run

docker run --rm -it -p 8080:3000 cloudkats/hello-world-rest
curl -i localhost:8080/env

Docker Compose

Run compose make run.

Dashboard http://localhost:8080/dashboard

Example runs

curl -s localhost:8080/api/rawdata | jq .
curl -H 'Host:whoami.docker.localhost' 'http://localhost/'
curl -i localhost:3000/echo/12345
curl -i localhost:3000/version
curl -i localhost:3000/status
curl -i localhost:3000/env
curl -i localhost:3000/env/rvm_

Create

Create a repository using this template →