package
Version:
v1.0.1
Opens a new window with list of versions in this module.
Published: Sep 17, 2020
License: MIT
Opens a new window with license information.
Imports: 18
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
AppKey secret key value for JWT
AuthMiddleware is middleware to check token is valid. Returning
a 401 status to the client if it is not valid.
InitDB setup database for use
func InitializeRoutes(env *Env)
InitializeRoutes setup route mappings
type Conf struct {
SQLConf `yaml:"mysql-config"`
JWTConf `yaml:"jwt-config"`
}
Conf contains yaml values
GetConf setup database for use
Env contains data required to start
type JWTConf struct {
Secret string `yaml:"secret"`
}
JWTConf contains config for jwt
type SQLConf struct {
Name string `yaml:"name"`
Usename string `yaml:"username"`
Password string `yaml:"password"`
Port string `yaml:"port"`
Host string `yaml:"host"`
}
SQLConf contains config for initializing the mysql db
Source Files
¶
Click to show internal directories.
Click to hide internal directories.