Documentation ¶
Index ¶
Constants ¶
View Source
const ( // PostgresProvider is the string used to refer to postgres. PostgresProvider = "postgres" // MySQLProvider is the string used to refer to MySQL. MySQLProvider = "mysql" )
Variables ¶
View Source
var ( // Providers represents this package's offering to the dependency manager. Providers = 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 { CreateTestUser *types.TestUserCreationConfig `json:"create_test_user" mapstructure:"create_test_user" toml:"create_test_user,omitempty"` Provider string `json:"provider" mapstructure:"provider" toml:"provider,omitempty"` ConnectionDetails database.ConnectionDetails `json:"connection_details" mapstructure:"connection_details" toml:"connection_details,omitempty"` Debug bool `json:"debug" mapstructure:"debug" toml:"debug,omitempty"` RunMigrations bool `json:"run_migrations" mapstructure:"run_migrations" toml:"run_migrations,omitempty"` MaxPingAttempts uint8 `json:"max_ping_attempts" mapstructure:"max_ping_attempts" toml:"max_ping_attempts,omitempty"` // contains filtered or unexported fields }
Config represents our database configuration.
Click to show internal directories.
Click to hide internal directories.