feat(api): doc folders curd implemention

This commit is contained in:
neo-f
2023-03-23 21:27:28 +08:00
parent 28edda5c7a
commit 6851fe95a0
17 changed files with 539 additions and 155 deletions

View File

@@ -13,20 +13,30 @@ import (
"github.com/spf13/viper"
)
type Config struct {
IsLocal bool
Debug bool `mapstructure:"debug"`
HTTPPort int `mapstructure:"http_port" validate:"required"`
type casdoorConfig struct {
Endpoint string `validate:"required" mapstructure:"endpoint"`
ClientID string `validate:"required" mapstructure:"client_id"`
ClientSecret string `validate:"required" mapstructure:"client_secret"`
Certificate string `validate:"required" mapstructure:"certificate"`
OrganizationName string `validate:"required" mapstructure:"organization_name"`
AppName string `validate:"required" mapstructure:"app_name"`
}
type Config struct {
IsLocal bool
Debug bool `mapstructure:"debug"`
HTTPPort int `mapstructure:"http_port" validate:"required"`
Host string `mapstructure:"host" validate:"required"`
Casdoor casdoorConfig `mapstructure:"casdoor"`
Databases struct {
OSS string `mapstructure:"oss" validate:"required"`
Storage string `mapstructure:"storage" validate:"required"`
PostgreSQL string `mapstructure:"postgresql" validate:"required"`
Qdrant string `mapstructure:"qdrant" validate:"required"`
} `mapstructure:"databases"`
Sentry struct {
Environment string
DSN string
}
Environment string `mapstructure:"environment"`
DSN string `mapstructure:"dsn"`
} `mapstructure:"sentry"`
}
var (