{"modulePath":"github.com/liquidgecka/blobby","version":"v0.0.0-20261108055455-e9a390ceacc7","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package httpserver\n\n## Types\n\n```go\ntype NameSpaceSettings struct {\n\t// The Storage implementation that is serving this specific name space\n\t// within the server.\n\tStorage *storage.Storage\n\n\t// Protections around the Blast Path API access for this specific\n\t// name space.\n\tBlastPathACL *access.ACL\n\n\t// Protections around replica related operations. Servers in this Access\n\t// Control List will be able to create, update, and destroy replicas\n\t// on this server.\n\tPrimaryACL *access.ACL\n\n\t// Protections around read access for this specific name space.\n\tReadACL *access.ACL\n\n\t// Protections around insert access for this specific name space.\n\tInsertACL *access.ACL\n}\n```\nEach name space is given a specific security ACL configuration that allows it to be protected.\n\n```go\ntype Server interface {\n\tAddr() string\n\tListen() error\n\tRun() error\n}\n```\nAn implementation of Server that exposes the public functions.\n\n```go\nfunc New(settings *Settings) Server\n```\nCreates a new Server that is capable of serving HTTP requests.\n\n```go\ntype Settings struct {\n\t// The address and port that should be listened on for this server.\n\tAddr string\n\tPort int\n\n\t// A list of namespaces, mapped by name, that should be served\n\t// by this HTTP server.\n\tNameSpaces map[string]*NameSpaceSettings\n\n\t// Enable tracing for requests. Adds debugging but impacts performance\n\t// slightly.\n\tEnableTracing bool\n\n\t// If TLS is desired then this loader should be non nil and it should\n\t// return certificates to be used for serving on the TLS ports.\n\tTLSCerts *secretloader.Certificate\n\n\t// Debugging ACL\n\tEnableDebugPaths bool\n\tDebugPathsACL    *access.ACL\n\n\t// Health checking ACL\n\tHealthCheckACL *access.ACL\n\n\t// Status endpoint ACL\n\tStatusACL *access.ACL\n\n\t// Shut down endpoint ACL\n\tShutDownACL *access.ACL\n\n\t// The Logger that will be used for all logs.\n\tLogger *slog.Logger\n\n\t// HTTP requests will be logged to this logger for access/request\n\t// logging. This is optional, if its left nil then no access logging\n\t// will be processed.\n\tAccessLogger *slog.Logger\n\n\t// These settings will be mapped into the underlying http.Server\n\t// object.\n\tWriteTimeout   time.Duration\n\tReadTimeout    time.Duration\n\tIdleTimeout    time.Duration\n\tMaxHeaderBytes int\n\n\t// The prefix for the namespace= tag; a value of blobby_ for this field\n\t// would give blobby_namespace as the tag key in the rendered Prometheus\n\t// metrics:\n\tPrometheusTagPrefix string\n\n\t// If defined then web authentication will be enabled and users will\n\t// be allowed to authenticate to Blobby using a static web login form\n\t// server from _login.\n\tWebAuthProvider *access.WebAuthProvider\n\n\t// We allow SAML authentication from multiple sources. Each needs to be\n\t// configured and named. This stores a mapping of name to SAML\n\t// name to authentication details.\n\tSAMLAuth map[string]*access.SAML\n}\n```\n\n","path":"github.com/liquidgecka/blobby/httpserver","name":"httpserver","synopsis":"","isRedistributable":true}
