Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Branding that's our name Branding = branding{"vouch", "VOUCH", "Vouch", "lasso", "https://github.com/vouch/vouch-proxy"} // Cfg the main exported config variable Cfg config // GenOAuth exported OAuth config variable // TODO: I think GenOAuth and OAuthConfig can be combined! // perhaps by https://golang.org/doc/effective_go.html#embedding GenOAuth *oauthConfig // OAuthClient is the configured client which will call the provider // this actually carries the oauth2 client ala oauthclient.Client(oauth2.NoContext, providerToken) OAuthClient *oauth2.Config // OAuthopts authentication options OAuthopts oauth2.AuthCodeOption // Providers static strings to test against Providers = &OAuthProviders{ Google: "google", GitHub: "github", IndieAuth: "indieauth", ADFS: "adfs", OIDC: "oidc", HomeAssistant: "homeassistant", OpenStax: "openstax", } // RequiredOptions must have these fields set for minimum viable config RequiredOptions = []string{"oauth.provider", "oauth.client_id"} // RootDir is where Vouch Proxy looks for ./config/config.yml, ./data, ./static and ./templates RootDir string )
Functions ¶
func BasicTest ¶ added in v0.2.4
func BasicTest() error
BasicTest just a quick sanity check to see if the config is sound
func InitForTestPurposes ¶ added in v0.5.8
func InitForTestPurposes()
InitForTestPurposes is called by most *_testing.go files in Vouch Proxy
func SetDefaults ¶ added in v0.5.8
func SetDefaults()
SetDefaults set default options for some items
func UnmarshalKey ¶
UnmarshalKey populate struct from contents of cfg tree at key
Types ¶
Click to show internal directories.
Click to hide internal directories.