Help us shape the future of Go! Take the 2026 Go Developer Survey

devgateway

package
v0.4.20 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2026 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DestroyTarget

func DestroyTarget(ctx context.Context, runtime Runtime, target string) error

func Reconcile

func Reconcile(ctx context.Context, runtime Runtime, issuer serviceaccess.Issuer, target string) error

func RemoveOwners

func RemoveOwners(ctx context.Context, runtime Runtime, issuer serviceaccess.Issuer, target string, owners ...string) error

func ReplaceOwnerRoutes

func ReplaceOwnerRoutes(ctx context.Context, runtime Runtime, issuer serviceaccess.Issuer, target, owner string, routes []Route) error

func ReplaceRoutes

func ReplaceRoutes(ctx context.Context, runtime Runtime, issuer serviceaccess.Issuer, target string, groups ...OwnerRoutes) error

func URL

func URL(host string) string

func URLForRuntime

func URLForRuntime(target, host string, runtime Runtime) string

URLForRuntime returns the effective canonical gateway URL before or after gateway state exists. Persisted state remains authoritative; on first reconciliation the runtime determines the same deterministic host port that Reconcile will persist (Docker 443, rootless Podman 8443).

func URLForTarget

func URLForTarget(target, host string) string

func UpsertOwnerRoutes

func UpsertOwnerRoutes(ctx context.Context, runtime Runtime, issuer serviceaccess.Issuer, target, owner string, routes []Route) error

func Verify

func Verify(ctx context.Context, target string) error

func VerifyHosts

func VerifyHosts(ctx context.Context, target string, hosts []string) error

Types

type Files

type Files struct {
	Dir       string
	State     string
	Compose   string
	Env       string
	Caddyfile string
	Project   string
	Cert      string
	Key       string
	CA        string
}

func FilesFor

func FilesFor(target string) (Files, error)

type OwnerRoutes

type OwnerRoutes struct {
	Owner  string
	Routes []Route
}

type Route

type Route struct {
	Owner      string `json:"owner"`
	Key        string `json:"key"`
	Host       string `json:"host"`
	PathPrefix string `json:"path_prefix,omitempty"`
	Upstream   string `json:"upstream"`
	Network    string `json:"network"`
	TrustFile  string `json:"trust_file"`
	ServerName string `json:"server_name"`
}

func Routes

func Routes(target string) ([]Route, error)

type Runtime

type Runtime interface {
	ConfigProject(context.Context, string, string, string) error
	UpProject(context.Context, string, string, string) error
	DestroyProject(context.Context, string, string, string) error
}

Jump to

Keyboard shortcuts

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