A small app written in golang to echo HTTP client's IP.
Live here: wiam.cc
These are the Docker Hub autobuild images located here.
GET /
{
"city": "Frankfurt am Main",
"country": "Germany",
"ip": "37.120.196.54"
}
GET /request?whatever
{
"host": "wiam.cc",
"method": "GET",
"proto": "HTTP/1.0",
"uri": "/request?whatever"
}
GET /header
{
"Accept": [
"text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9"
],
"Accept-Encoding": [
"gzip, deflate, br"
],
"Accept-Language": [
"en-GB,en;q=0.9,en-US;q=0.8,vi;q=0.7,de;q=0.6"
],
...
"User-Agent": [
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.107 Safari/537.36 Edg/92.0.902.55"
],
"Via": [
"2.0 d91961fd00a0c4f7aae668984dcb62a8.cloudfront.net (CloudFront)"
],
"X-Amz-Cf-Id": [
"ipaVdETgdefi9vQAvH31Wy2ObjyctilDNMBpm9VtdaJISURf3CZPTg=="
],
"X-Forwarded-For": [
"37.120.196.54"
]
}
Default production mode
docker run -p 8080:8080 -d locnh/wiam
or GIN debug
docker run -p 8080:8080 -e GIN_MODE=debug -d locnh/wiam
- Fork me
- Make changes
- Create pull request
- Grab a cup of tee and enjoy