Documentation ¶
Overview ¶
Package config provides basic configuration plumbing.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var GetConf = func() *Config { if sConf == nil { Reload() } return sConf }
GetConf will get the configuration settings for the MServ server. Subsequent calls will NOT refresh the settings if they have since changed. For that to happen, call Reload first.
View Source
var GetSubConf = func(in interface{}, envTag string) error { if err := envconfig.Process(envTag, in); err != nil { log.WithError(err).Fatal("failed to process config env vars") } if err := json.Unmarshal(conf.ReadConf(), in); err != nil { return fmt.Errorf("failed to unmarshal mserv driver config: %w", err) } return nil }
GetConf will get the config data for the Momo Driver
Functions ¶
Types ¶
type FileStorage ¶
type FileStorage struct { S3 *AWSS3 Local *LocalStore Kind string `default:"local"` }
type LocalStore ¶
type LocalStore struct {
ConfigKeyPath string `default:"/tmp/mserv/filestore-local"`
}
type MservConf ¶
type MservConf struct { StorageTag string StoreType StorageDriver AllowHttpInvocation bool HTTPAddr string `default:":8989"` GrpcServer struct { Address string Enabled bool } PublicKeyPath string MiddlewarePath string `default:"/tmp/mserv/middleware"` PluginDir string `default:"/tmp/mserv/plugins"` RetainUploads bool FileStore *FileStorage }
MservConf describes the settings required for an Mserv instance
type StorageDriver ¶
type StorageDriver string
Click to show internal directories.
Click to hide internal directories.