Documentation
¶
Index ¶
- type Api
- type Bot
- type Cert
- type Certs
- type Config
- func (c *Config) AddApi(api Api)
- func (c *Config) AddDb(db Database)
- func (c *Config) AddService(service Service)
- func (c *Config) GetApi(name string) (bool, *Api)
- func (c *Config) GetBot(name string) (bool, *Bot)
- func (c *Config) GetCert(name string) (bool, *Cert)
- func (c *Config) GetDB(name string) (bool, *Database)
- func (c *Config) GetJwt(name string) (bool, *Jwt)
- func (c *Config) GetService(name string) (bool, *Service)
- func (c *Config) RemoveApi(api Api)
- func (c *Config) RemoveDb(db Database)
- func (c *Config) RemoveService(service Service)
- func (c *Config) Save() error
- type Cors
- type Database
- type Gateway
- type Https
- type Jwt
- type Log
- type Param
- type Params
- type Service
- type Swagger
- type Trace
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Api ¶
type Api struct {
Name string `json:"name"`
Host string `json:"host"`
Port int `json:"port"`
Path string `json:"path"`
Swagger Swagger `json:"swagger"`
Cors Cors `json:"cors"`
Https Https `json:"https"`
Gateway Gateway `json:"gateway"`
Dbs []string `json:"dbs"`
Ativo bool `json:"ativo"`
}
func (*Api) GetPortStr ¶
type Config ¶
type Config struct {
Dbs []*Database `json:"dbs"`
Services []*Service `json:"services"`
Bots []*Bot `json:"bots"`
Apis []*Api `json:"apis"`
Jwt []*Jwt `json:"jwt"`
Parans Params `json:"parans"`
Certs Certs `json:"certs"`
Log Log `json:"log"`
Path string `json:"path"`
JsonFile string
}
var InstanceConfig *Config
func (*Config) AddService ¶
func (*Config) RemoveService ¶
type Cors ¶
type Cors struct {
MaxAge int `json:"maxAge"`
AllowCredentials bool `json:"allowCredentials"`
AllowHeaders []string `json:"allowHeaders"`
ExposedHeaders []string `json:"exposedHeaders"`
AllowMethods []string `json:"allowMethods"`
AllowOrigins []string `json:"allowOrigins"`
Ativo bool `json:"ativo"`
}
type Database ¶
type Database struct {
Name string `json:"name"`
Host string `json:"host"`
Port int `json:"port"`
User string `json:"user"`
Pass string `json:"pass"`
Schema string `json:"schema"`
Sid string `json:"sid"`
PoolSize int `json:"poolsize"`
MaxConn int `json:"maxconn"`
Ativo bool `json:"ativo"`
Trace Trace `json:"trace"`
Db string `json:"db"`
}
Click to show internal directories.
Click to hide internal directories.