config

package
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 21, 2022 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Database = struct {
	Filename string
}{
	Filename: asString(withDefault("database.filename", "wiki.sqlite3.db")),
}
View Source
var HTTP = struct {
	Host              string
	Port              int
	TrustProxyHeaders bool
	ExternalURL       string
	SecureCookies     bool
}{
	Host:              asString(withDefault("http.host", "0.0.0.0")),
	Port:              asInt(withDefault("http.port", 8080)),
	TrustProxyHeaders: asBool(fetchFromFile("http.trustProxyHeaders")),
	ExternalURL:       asString(withDefault("http.externalURL", "https://localhost")),
	SecureCookies:     asBool(withDefault("http.secureCookies", true)),
}
View Source
var SAML = &samlConfig{
	Autoload:        asBool(fetchFromFile("saml.autoload")),
	MetadataURL:     asString(fetchFromFile("saml.metadataURL")),
	EntityID:        asString(fetchFromFile("saml.idp.entityID")),
	SSOURL:          asString(fetchFromFile("saml.idp.ssoURL")),
	rawIDPCert:      asString(fetchFromFile("saml.idp.signingCertificate")),
	NameMappingKey:  asString(withDefault("saml.mappings.name", "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name")),
	EmailMappingKey: asString(withDefault("saml.mappings.email", "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress")),
}

Functions

func InitLogging

func InitLogging()

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL