env

package
v0.0.0-...-73c8340 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseEnv

type BaseEnv struct {
	// contains filtered or unexported fields
}

BaseEnv is the struct containing server state that is valid across multiple sessions for example, database connections and config information.

func New

func New(audience string) *BaseEnv

New creates a new base environment use by all our services.

func (*BaseEnv) Audience

func (e *BaseEnv) Audience() string

Audience returns the audience that should be associated with any JWT keys.

func (*BaseEnv) JWTSigningKey

func (e *BaseEnv) JWTSigningKey() string

JWTSigningKey returns the JWT key.

type Env

type Env interface {
	JWTSigningKey() string
	Audience() string
}

Env is the interface that all sub-environments should implement.

Jump to

Keyboard shortcuts

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