diff --git a/README.md b/README.md index 7a5ddda..ac28d93 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,23 @@ ifconfig ======== -Yet Another ifconfig inspired by http://ifconfig.me, the online demo is [https://ifconfig.minidump.info](https://ifconfig.minidump.info). +Yet Another ifconfig inspired by http://ifconfig.me, the online demo is [https://whois.envs.net](https://whois.envs.net). -[![Build Status](https://secure.travis-ci.org/dfordsoft/ifconfig.png)](https://travis-ci.org/dfordsoft/ifconfig) [![GitHub release](https://img.shields.io/github/release/dfordsoft/ifconfig.svg?maxAge=2592000)](https://github.com/dfordsoft/ifconfig/releases) [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/dfordsoft/ifconfig/master/LICENSE) +[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/dfordsoft/ifconfig/master/LICENSE) -Build +Install / Build +---- +```bash +wget -O /opt/ https://dl.google.com/go/go1.12.6.linux-amd64.tar.gz +tar -C /usr/local -xzf /opt/go1.12.6.linux-amd64.tar.gz +git clone https://github.com/cremesk/ifconfig.git + +go get github.com/cremesk/ifconfig +go build main.go +``` + +Download ---- -`go get github.com/dfordsoft/ifconfig` - -Download ----- - -Click this button to download the binary for your platform: [![GitHub release](https://img.shields.io/github/release/dfordsoft/ifconfig.svg?maxAge=2592000)](https://github.com/dfordsoft/ifconfig/releases) \ No newline at end of file +Click this button to download the binary for your platform: [![GitHub release](https://img.shields.io/github/release/dfordsoft/ifconfig.svg?maxAge=2592000)](https://github.com/dfordsoft/ifconfig/releases) diff --git a/views/index.tpl b/views/index.tpl index b71f8e1..14e7725 100644 --- a/views/index.tpl +++ b/views/index.tpl @@ -38,7 +38,7 @@ #footer{background:#777;height:20px;line-height:20px;color:#ddd;text-align:center;margin-top:15px;border-top:none;} #ip_address{font-size:1.9em;} #ip_address_cell{padding:5px;height:50px;} - + #plungins{height:20px;float:right;} .plungin{float:right;} #button_twitter{width:100px;} @@ -52,7 +52,7 @@ @@ -125,27 +125,27 @@

Command Line Interface

-

What Is My IP Address? - Yet Another ifconfig

+

What Is My IP Address? - Yet Another ifconfig

- - - - - - - - - - - - - - - + + + + + + + + + + + + + + - +
$ curl https://ifconfig.minidump.info{{.IP}}
$ curl https://ifconfig.minidump.info/ip{{.IP}}
$ curl https://ifconfig.minidump.info/host{{.Host}}
$ curl https://ifconfig.minidump.info/ua{{.UserAgent}}
$ curl https://ifconfig.minidump.info/port{{.Port}}
$ curl https://ifconfig.minidump.info/lang{{.Lang}}
$ curl https://ifconfig.minidump.info/keepalive{{.Keepalive}}
$ curl https://ifconfig.minidump.info/connection{{.Connection}}
$ curl https://ifconfig.minidump.info/encoding{{.Encoding}}
$ curl https://ifconfig.minidump.info/mime{{.Mime}}
$ curl https://ifconfig.minidump.info/charset{{.Charset}}
$ curl https://ifconfig.minidump.info/via{{.Via}}
$ curl https://ifconfig.minidump.info/forwarded{{.Forwarded}}
$ curl https://ifconfig.minidump.info/allip_addr: {{.IP}}
remote_host: {{.Host}}
user_agent: {{.UserAgent}}
port: {{.Port}}
lang: {{.Lang}}
connection: {{.Connection}}
keep_alive: {{.Keepalive}}
encoding: {{.Encoding}}
mime: {{.Mime}}
charset: {{.Charset}}
via: {{.Via}}
forwarded: {{.Forwarded}}
$ curl https://ifconfig.minidump.info/all.xml<info>
    <charset>{{.Charset}}</charset>
    <connection>{{.Connection}}</connection>
    <encoding>{{.Encoding}}</encoding>
    <forwarded>{{.Forwarded}}</forwarded>
    <ip_addr>{{.IP}}</ip_addr>
    <keep_alive>{{.Keepalive}}</keep_alive>
    <lang>{{.Lang}}</lang>
    <mime>{{.Mime}}</mime>
    <port>{{.Port}}</port>
    <remote_host>{{.Host}}</remote_host>
    <user_agent>{{.UserAgent}}</user_agent>
    <via>{{.Via}}</via>
+
$ curl https://whois.envs.net{{.IP}}
$ curl https://whois.envs.net/ip{{.IP}}
$ curl https://whois.envs.net/host{{.Host}}
$ curl https://whois.envs.net/ua{{.UserAgent}}
$ curl https://whois.envs.net/port{{.Port}}
$ curl https://whois.envs.net/lang{{.Lang}}
$ curl https://whois.envs.net/keepalive{{.Keepalive}}
$ curl https://whois.envs.net/connection{{.Connection}}
$ curl https://whois.envs.net/encoding{{.Encoding}}
$ curl https://whois.envs.net/mime{{.Mime}}
$ curl https://whois.envs.net/charset{{.Charset}}
$ curl https://whois.envs.net/via{{.Via}}
$ curl https://whois.envs.net/forwarded{{.Forwarded}}
$ curl https://whois.envs.net/allip_addr: {{.IP}}
remote_host: {{.Host}}
user_agent: {{.UserAgent}}
port: {{.Port}}
lang: {{.Lang}}
connection: {{.Connection}}
keep_alive: {{.Keepalive}}
encoding: {{.Encoding}}
mime: {{.Mime}}
charset: {{.Charset}}
via: {{.Via}}
forwarded: {{.Forwarded}}
$ curl https://whois.envs.net/all.xml<info>
    <charset>{{.Charset}}</charset>
    <connection>{{.Connection}}</connection>
    <encoding>{{.Encoding}}</encoding>
    <forwarded>{{.Forwarded}}</forwarded>
    <ip_addr>{{.IP}}</ip_addr>
    <keep_alive>{{.Keepalive}}</keep_alive>
    <lang>{{.Lang}}</lang>
    <mime>{{.Mime}}</mime>
    <port>{{.Port}}</port>
    <remote_host>{{.Host}}</remote_host>
    <user_agent>{{.UserAgent}}</user_agent>
    <via>{{.Via}}</via>
</info>
$ curl https://ifconfig.minidump.info/all.json{"connection":"{{.Connection}}","ip_addr":"{{.IP}}","lang":"{{.Lang}}","remote_host":"{{.Host}}","user_agent":"{{.UserAgent}}","charset":"{{.Charset}}","port":"{{.Port}}","via":"{{.Via}}","forwarded":"{{.Forwarded}}","mime":"{{.Mime}}","keep_alive":"{{.Keepalive}}","encoding":"{{.Encoding}}"}
$ curl https://whois.envs.net/all.json{"connection":"{{.Connection}}","ip_addr":"{{.IP}}","lang":"{{.Lang}}","remote_host":"{{.Host}}","user_agent":"{{.UserAgent}}","charset":"{{.Charset}}","port":"{{.Port}}","via":"{{.Via}}","forwarded":"{{.Forwarded}}","mime":"{{.Mime}}","keep_alive":"{{.Keepalive}}","encoding":"{{.Encoding}}"}
- + - +