Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // DatabaseConfigProviders represents this package's offering to the dependency manager. DatabaseConfigProviders = wire.NewSet( ProvideSessionManager, ) )
Functions ¶
func ProvideSessionManager ¶
func ProvideSessionManager(cookieConfig *authservice.CookieConfig, dm database.DataManager) (*scs.SessionManager, error)
ProvideSessionManager provides a session manager based on some settings. There's not a great place to put this function. I don't think it belongs in Auth because it accepts a DB connection, but it obviously doesn't belong in the database package, or maybe it does.
Types ¶
type Config ¶
type Config struct { OAuth2TokenEncryptionKey string `json:"oauth2TokenEncryptionKey" toml:"oauth2_token_encryption_key,omitempty"` ConnectionDetails string `json:"connectionDetails" toml:"connection_details,omitempty"` Debug bool `json:"debug" toml:"debug,omitempty"` LogQueries bool `json:"logQueries" toml:"log_queries,omitempty"` RunMigrations bool `json:"runMigrations" toml:"run_migrations,omitempty"` MaxPingAttempts uint64 `json:"maxPingAttempts" toml:"max_ping_attempts,omitempty"` PingWaitPeriod time.Duration `json:"pingWaitPeriod" toml:"ping_wait_period,omitempty"` // contains filtered or unexported fields }
Config represents our database configuration.
Click to show internal directories.
Click to hide internal directories.