server

package
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2026 License: MIT Imports: 23 Imported by: 0

Documentation

Overview

Package server implements the Epoch HTTP server.

It serves two APIs:

  • /v2/ — OCI Distribution-shaped push/pull protocol (manifests + blob streaming via object storage)
  • /api/ — Control plane API backed by MySQL

Static frontend files are embedded and served at /.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SSOConfig

type SSOConfig struct {
	Provider     string
	ClientID     string
	ClientSecret string //nolint:gosec // OAuth configuration schema field name
	RedirectURI  string
	AuthorizeURL string
	TokenURL     string
	UserInfoURL  string
	LogoutURL    string
	Scopes       string
	HostedDomain string
	CookieSecret []byte
}

SSOConfig holds optional UI auth settings loaded from the environment.

func LoadSSOConfig

func LoadSSOConfig(ctx context.Context) *SSOConfig

LoadSSOConfig reads optional UI auth configuration from the environment.

type Server

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

Server is the Epoch HTTP server.

func New

func New(ctx context.Context, reg *registry.Registry, st *store.Store, addr string) *Server

New creates a new server.

func (*Server) ListenAndServe

func (s *Server) ListenAndServe(ctx context.Context) error

ListenAndServe starts the server with initial sync and background sync.

Jump to

Keyboard shortcuts

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