Documentation
¶
Overview ¶
Package central is the server: edge API, web API, storage and alerting.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DoctorSteps ¶ added in v1.1.0
func DoctorSteps(cfg DoctorConfig) ([]doctor.Step, func())
DoctorSteps checks, in order, what the central needs: the database, the TimescaleDB extension, the schema, the edges and checks, whether the edges report, and how the edge API is exposed. The returned function releases what the steps opened.
Types ¶
type DoctorConfig ¶ added in v1.1.0
type DoctorConfig struct {
DatabaseURL string
EdgeListen string
APIListen string
// EdgeTLSCert and APITLSCert are the certificate files the surfaces serve,
// when they serve TLS themselves.
EdgeTLSCert string
APITLSCert string
// SecretKeyFile is the file of the key that encrypts the channels, if any.
SecretKeyFile string
// Now is the clock; nil means time.Now.
Now func() time.Time
}
DoctorConfig is what the central diagnostics need.
type Option ¶ added in v1.1.0
type Option func(*Server)
Option changes how the edge API is built.
func WithProxies ¶ added in v1.1.0
WithProxies names the reverse proxies trusted to say who the client is.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package alert opens an incident when a check keeps failing or an edge goes quiet, resolves it when it stops, and tells the channels of each event.
|
Package alert opens an incident when a check keeps failing or an edge goes quiet, resolves it when it stops, and tells the channels of each event. |
|
Package auth hashes passwords, enforces their policy and throttles login attempts.
|
Package auth hashes passwords, enforces their policy and throttles login attempts. |
|
Package store keeps edges, checks and results in PostgreSQL with TimescaleDB.
|
Package store keeps edges, checks and results in PostgreSQL with TimescaleDB. |
|
storetest
Package storetest gives tests a throwaway database; tests skip without NETPROBE_TEST_DATABASE_URL.
|
Package storetest gives tests a throwaway database; tests skip without NETPROBE_TEST_DATABASE_URL. |
|
Package webapi is the JSON API the web UI talks to: accounts, sessions and the data of the central.
|
Package webapi is the JSON API the web UI talks to: accounts, sessions and the data of the central. |
Click to show internal directories.
Click to hide internal directories.