Versions in this module Expand all Collapse all v0 v0.1.1 Jul 10, 2025 v0.1.0 Jul 10, 2025 Changes in this version + const DefaultTimeoutSeconds + const ModuleName + var ErrNoHandler = errors.New("no HTTP handler available") + var ErrServerNotStarted = errors.New("server not started") + func NewHTTPServerModule() modular.Module + type CertificateService interface + GetCertificate func(*tls.ClientHelloInfo) (*tls.Certificate, error) + type HTTPServerConfig struct + Host string + IdleTimeout int + Port int + ReadTimeout int + ShutdownTimeout int + TLS *TLSConfig + WriteTimeout int + func (c *HTTPServerConfig) GetTimeout(seconds int) time.Duration + func (c *HTTPServerConfig) Validate() error + type HTTPServerModule struct + func (m *HTTPServerModule) Constructor() modular.ModuleConstructor + func (m *HTTPServerModule) Init(app modular.Application) error + func (m *HTTPServerModule) Name() string + func (m *HTTPServerModule) ProvidesServices() []modular.ServiceProvider + func (m *HTTPServerModule) RegisterConfig(app modular.Application) error + func (m *HTTPServerModule) RequiresServices() []modular.ServiceDependency + func (m *HTTPServerModule) Start(ctx context.Context) error + func (m *HTTPServerModule) Stop(ctx context.Context) error + type TLSConfig struct + AutoGenerate bool + CertFile string + Domains []string + Enabled bool + KeyFile string + UseService bool