1
0
mirror of https://git.envs.net/envs/ifconfig synced 2024-11-22 09:51:57 +01:00

update to envs.net

This commit is contained in:
creme 2019-09-13 22:48:37 +02:00
parent 00cf1bbaa4
commit 473befd971
No known key found for this signature in database
GPG Key ID: C147C3B7FBDF08D0
4 changed files with 12 additions and 12 deletions

@ -1,19 +1,19 @@
ifconfig ifconfig
======== ========
Yet Another ifconfig inspired by http://ifconfig.me, the online demo is [https://whois.envs.net](https://whois.envs.net). Yet Another ifconfig inspired by http://ifconfig.me, the online demo is [https://ip.envs.net](https://ip.envs.net).
[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/cremesk/ifconfig/master/LICENSE) [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/envs-net/ifconfig/master/LICENSE)
Install / Build Install / Build
---- ----
```bash ```bash
wget -O /opt/ https://dl.google.com/go/go1.12.6.linux-amd64.tar.gz wget -O /opt/ https://dl.google.com/go/go1.13.linux-amd64.tar.gz
tar -C /usr/local -xzf /opt/go1.12.6.linux-amd64.tar.gz tar -C /usr/local -xzf /opt/go1.13.linux-amd64.tar.gz
git clone https://github.com/cremesk/ifconfig.git git clone https://github.com/envs-net/ifconfig.git
go get github.com/cremesk/ifconfig go get github.com/envs.net/ifconfig
go build main.go go build main.go
``` ```

@ -102,7 +102,7 @@ func (this *MainController) GetKeepAlive() {
} }
func (this *MainController) GetAll() { func (this *MainController) GetAll() {
this.Data["Email"] = "missdeer@dfordsoft.com" this.Data["Email"] = "hostmaster@envs.net"
this.Data["UserAgent"] = this.Ctx.Request.UserAgent() this.Data["UserAgent"] = this.Ctx.Request.UserAgent()
ip := this.Ctx.Input.IP() ip := this.Ctx.Input.IP()
names, err := net.LookupAddr(ip) names, err := net.LookupAddr(ip)
@ -169,7 +169,7 @@ type ifconfig struct {
func (this *MainController) GetAllXML() { func (this *MainController) GetAllXML() {
thisData := ifconfig{} thisData := ifconfig{}
thisData.Email = "missdeer@dfordsoft.com" thisData.Email = "hostmaster@envs.net"
thisData.UserAgent = this.Ctx.Request.UserAgent() thisData.UserAgent = this.Ctx.Request.UserAgent()
ip := this.Ctx.Input.IP() ip := this.Ctx.Input.IP()
@ -221,7 +221,7 @@ func (this *MainController) GetAllXML() {
func (this *MainController) GetAllJSON() { func (this *MainController) GetAllJSON() {
thisData := make(map[string]interface{}) thisData := make(map[string]interface{})
thisData["Email"] = "missdeer@dfordsoft.com" thisData["Email"] = "hostmaster@envs.net"
thisData["UserAgent"] = this.Ctx.Request.UserAgent() thisData["UserAgent"] = this.Ctx.Request.UserAgent()
ip := this.Ctx.Input.IP() ip := this.Ctx.Input.IP()
names, err := net.LookupAddr(ip) names, err := net.LookupAddr(ip)
@ -275,7 +275,7 @@ func (this *MainController) Get() {
this.Abort("404") this.Abort("404")
return return
} }
this.Data["Email"] = "missdeer@dfordsoft.com" this.Data["Email"] = "hostmaster@envs.net"
this.Data["UserAgent"] = this.Ctx.Request.UserAgent() this.Data["UserAgent"] = this.Ctx.Request.UserAgent()
ip := this.Ctx.Input.IP() ip := this.Ctx.Input.IP()
names, err := net.LookupAddr(ip) names, err := net.LookupAddr(ip)

@ -4,7 +4,7 @@ import (
"os" "os"
"github.com/astaxie/beego" "github.com/astaxie/beego"
_ "github.com/dfordsoft/ifconfig/routers" _ "github.com/envs-net/ifconfig/routers"
) )
const ( const (

@ -2,7 +2,7 @@ package routers
import ( import (
"github.com/astaxie/beego" "github.com/astaxie/beego"
"github.com/dfordsoft/ifconfig/controllers" "github.com/envs-net/ifconfig/controllers"
) )
func init() { func init() {