Documentation ¶
Index ¶
- func Connect(user, password, host string, port int) (*ssh.Session, error)
- func GetAccountInfo(url, username string) (*util.AccountInfo, error)
- func MonitorConfigFile(configFile string) error
- func PathExist(_path string) bool
- func SaveIpPonixToBlockchain(myNodeIpaddr string) map[string]CityInfo
- func SshCommand(user, password, host string, port int, command string) (string, error)
- func WriteFile(filename string, nodeInfos NodeInfos) error
- type CityInfo
- type Country
- type CountryDetails
- type Ippointxy
- type MongoContext
- type MongoRepository
- type NodeCapacityInfo
- type NodeInfo
- type NodeInfos
- type StorageDBClusterInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAccountInfo ¶
func GetAccountInfo(url, username string) (*util.AccountInfo, error)
GetAccountInfo GetAccountInfo
func MonitorConfigFile ¶
MonitorConfigFile MonitorConfigFile
func SaveIpPonixToBlockchain ¶
SaveIpPonixToBlockchain SaveIpPonixToBlockchain
func SshCommand ¶
SshCommand SshCommand
Types ¶
type Country ¶
type Country struct { Country string Province string City string Latitude float32 Longitude float32 }
Country struct
type Ippointxy ¶
type Ippointxy struct { ID bson.ObjectId `bson:"_id"` Ip string `bson:"ip"` Pointx string `bson:"pointx"` Pointy string `bson:"pointy"` CreatedAt time.Time `bson:"createdAt"` }
Ippointxy struct
type MongoContext ¶
type MongoContext struct {
// contains filtered or unexported fields
}
MongoContext struct
func (*MongoContext) GetCollection ¶
func (c *MongoContext) GetCollection(db string, collection string) *mgo.Collection
GetCollection GetCollection
func (*MongoContext) SetCollectionByDB ¶
func (c *MongoContext) SetCollectionByDB(db string, collection string, s func(*mgo.Collection) error) error
SetCollectionByDB SetCollectionByDB
type MongoRepository ¶
type MongoRepository struct {
// contains filtered or unexported fields
}
MongoRepository struct
func NewMongoRepository ¶
func NewMongoRepository(endpoint string) *MongoRepository
NewMongoRepository NewMongoRepository
func (*MongoRepository) CallInsertPointxy ¶
func (r *MongoRepository) CallInsertPointxy(ip string, pointx string, pointy string) (uint32, error)
CallInsertPointxy CallInsertPointxy
func (*MongoRepository) InsertRecord ¶
func (r *MongoRepository) InsertRecord(tablename string, keyname string, key string, valueName string, value interface{}) (uint32, error)
InsertRecord InsertRecord
type NodeCapacityInfo ¶
type NodeCapacityInfo struct { NodeUUID string `json:nodeuuid` NodeIP string `json:nodeip` StorageCapacity string `json:storagecapacity` }
NodeCapacityInfo struct
type NodeInfo ¶
type NodeInfo struct { NodeName string IpAddr string UserName string PassWord string BtoPort string BtoUser string BtoPath string WalletIP string KeyPath string ProdUser string DbUser string DbPass string StorageSize string StoragePath string ServPath string ServLst []string SeedIp string SlaveIpLst []string StorageCapacity string }
NodeInfo struct
Click to show internal directories.
Click to hide internal directories.