new file structure & koneksi ke DB
This commit is contained in:
@@ -40,11 +40,14 @@ type Config struct {
|
||||
} `mapstructure:"shortlink"`
|
||||
|
||||
Database struct {
|
||||
Host string `mapstructure:"host"`
|
||||
Port int `mapstructure:"port"`
|
||||
User string `mapstructure:"user"`
|
||||
Password string `mapstructure:"password"`
|
||||
Name string `mapstructure:"name"`
|
||||
Host string `mapstructure:"host"`
|
||||
Port int `mapstructure:"port"`
|
||||
User string `mapstructure:"user"`
|
||||
Password string `mapstructure:"password"`
|
||||
Name string `mapstructure:"name"`
|
||||
MaxOpenConns int `mapstructure:"max_open_conns"`
|
||||
MaxIdleConns int `mapstructure:"max_idle_conns"`
|
||||
ConnMaxLifetimeMins int `mapstructure:"conn_max_lifetime_mins"`
|
||||
} `mapstructure:"database"`
|
||||
|
||||
AllowedOrigins []string `mapstructure:"allowed_origins"`
|
||||
|
||||
Reference in New Issue
Block a user