Go to file
Martin Polden f1a8819fa7 Read X-Real-IP header if set 2012-11-19 23:52:52 +01:00
.gitignore Ignore server binary 2012-11-19 19:55:22 +01:00
README.md Add README 2012-11-19 19:11:03 +01:00
ifconfig.go Read X-Real-IP header if set 2012-11-19 23:52:52 +01:00
index.html Add basic HTML template 2012-11-19 19:50:32 +01:00

README.md

ifconfig.co: Simple IP address lookup service

A simple service for looking up your IP address. This is the code that powers http://ifconfig.co

Basic usage

# The usual suspects
$ curl ifconfig.co
127.0.0.1
$ wget -O - ifconfig.co
127.0.0.1
# BSD fetch
$ fetch -o - ifconfig.co
127.0.0.1

Pass the appropriate flag (usually -4 and -6) to your tool to switch between IPv4 and IPv6 lookup.

Features

  • Easy to remember domain name
  • Supports IPv4 and IPv6
  • Open source
  • Fast
  • Supports typical CLI tools (curl, wget and fetch)

Why?

  • To scratch an itch
  • An excuse to use Go for something
  • Faster than ifconfig.me and has IPv6 support

Code style

$ gofmt -tabs=false -tabwidth=4