cmd

package
v0.0.0-...-f2e39e4 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2021 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Auth

type Auth struct {
	Audience  string `required:"true"`
	Issuer    string `required:"true"`
	PublicKey string `required:"true"`
}

type AuthGen

type AuthGen struct {
	Auth
	PrivateKey string `required:"true"`
}

type Config

type Config struct {
	Mongo   mongo.Config
	DBCache DBCache
	Network Network
	Sentry  ErrorTracking
	Auth0   Auth
	Local   AuthGen
	Users   UserDirectory
}

func MustGetConfiguration

func MustGetConfiguration() *Config

type DBCache

type DBCache struct {
	TTL time.Duration `envconfig:"DB_TTL" default:"1s"`
}

type ErrorTracking

type ErrorTracking struct {
	DSN string `envconfig:"SENTRY_DSN" default:""`
}

type Network

type Network struct {
	Port int `envconfig:"PORT" default:"80"`
}

func MustSetup

func MustSetup() Network

type UserDirectory

type UserDirectory struct {
	Domain       string
	ClientID     string        `envconfig:"CLIENT_ID"`
	ClientSecret string        `envconfig:"CLIENT_SECRET"`
	CacheTTL     time.Duration `envconfig:"CLIENT_TTL" default:"5m"`
	Connection   string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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