server

package
v0.0.0-...-52a538d Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2025 License: MIT Imports: 39 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	FrontendDomains = appenv.DecodeEnvList(os.Getenv("FRONTEND_DOMAINS_LIST"))
)

Functions

func Auth

func Auth(authRepo auth.Repository) func(http.Handler) http.HandlerFunc

func Installation

func Installation(authRepo auth.Repository) func(http.Handler) http.HandlerFunc

Inject the Installation into the request context, will respond with error if it can't find the Installation in the database or in the request headers

func NewPublicUserFromAuthUser

func NewPublicUserFromAuthUser(u auth.User) publicUser

func NewServer

func NewServer(ctx context.Context) *http.Server

func StripBearerToken

func StripBearerToken(tokenWithBearer string) string

Types

type Server

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

func (*Server) LoggerInjector

func (s *Server) LoggerInjector(h http.Handler) http.HandlerFunc

func (*Server) NewAuthRepository

func (s *Server) NewAuthRepository() auth.Repository

func (*Server) RegisterRoutes

func (s *Server) RegisterRoutes(ctx context.Context) http.Handler

Jump to

Keyboard shortcuts

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