init security, add cors
This commit is contained in:
@@ -6,6 +6,7 @@ type Config struct {
|
||||
Server ServerConfig
|
||||
Databases map[string]DatabaseConfig
|
||||
ReadReplicas map[string][]DatabaseConfig
|
||||
Security SecurityConfig
|
||||
}
|
||||
|
||||
type ServerConfig struct {
|
||||
@@ -43,3 +44,7 @@ type DatabaseConfig struct {
|
||||
MaxIdleTime time.Duration // Maximum amount of time a connection may be idle
|
||||
HealthCheckPeriod time.Duration // Health check period
|
||||
}
|
||||
|
||||
type SecurityConfig struct {
|
||||
TrustedOrigins []string `mapstructure:"trusted_origins"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user