Change directory structure, move models and utils to root directory

This commit is contained in:
fatedier
2016-02-18 16:56:55 +08:00
parent 30da2a2d15
commit 50165053f8
14 changed files with 76 additions and 67 deletions

View File

@@ -4,7 +4,7 @@ import (
"fmt"
"strconv"
"github.com/fatedier/frp/pkg/models"
"github.com/fatedier/frp/models/server"
ini "github.com/vaughan0/go-ini"
)
@@ -19,7 +19,7 @@ var (
HeartBeatTimeout int64 = 30
)
var ProxyServers map[string]*models.ProxyServer = make(map[string]*models.ProxyServer)
var ProxyServers map[string]*server.ProxyServer = make(map[string]*server.ProxyServer)
func LoadConf(confFile string) (err error) {
var tmpStr string
@@ -59,7 +59,7 @@ func LoadConf(confFile string) (err error) {
// servers
for name, section := range conf {
if name != "common" {
proxyServer := &models.ProxyServer{}
proxyServer := &server.ProxyServer{}
proxyServer.Name = name
proxyServer.Passwd, ok = section["passwd"]