server

package
v0.0.0-...-8af8fce Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2024 License: AGPL-3.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Protect

func Protect(db *config.DB, next http.Handler) http.Handler

func Run

func Run(ctx context.Context, db *config.DB, env Environ) error

func UpdateBaseConfig

func UpdateBaseConfig(ctx context.Context, db *config.DB, addr string, port uint, rootDir string) error

Types

type Config

type Config struct {
	Address string
	Port    uint
	RootDir string
}

func LoadConfig

func LoadConfig(ctx context.Context, db *config.DB) (Config, error)

type DynamicBindings

type DynamicBindings struct {
	Entries map[string]string
}

func UpdateDynamicBinds

func UpdateDynamicBinds(ctx context.Context, db *config.DB, environ func() []string, expandEnv func(string) string) (*DynamicBindings, error)

type Environ

type Environ struct {
	Entries func() []string
	Expand  func(string) string
}

Jump to

Keyboard shortcuts

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