internal/

directory
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2026 License: AGPL-3.0

Directories

Path Synopsis
Package agent is the edgeweir-node runtime (`edgeweir-node run`).
Package agent is the edgeweir-node runtime (`edgeweir-node run`).
Package bans holds the dynamic IP bans the console distributes outside configuration revisions (GetBans).
Package bans holds the dynamic IP bans the console distributes outside configuration revisions (GetBans).
Package captcha draws the image captchas of the captcha challenge with the standard library only: a built-in 5x7 dot-matrix font, randomly placed, scaled, rotated and sheared characters on a wavy baseline, with noise lines and dots, encoded as a small paletted PNG.
Package captcha draws the image captchas of the captcha challenge with the standard library only: a built-in 5x7 dot-matrix font, randomly placed, scaled, rotated and sheared characters on a wavy baseline, with noise lines and dots, encoded as a small paletted PNG.
Package challengeverify checks the answers of third-party CAPTCHA widgets (the interactive challenge's providers, feature challenge-v3) with the provider's server-side API.
Package challengeverify checks the answers of third-party CAPTCHA widgets (the interactive challenge's providers, feature challenge-v3) with the provider's server-side API.
Package configir handles the engine-agnostic NodeConfig IR on the node: canonical ordering, content hashing, diff application and validation into a Plan that the data plane renderers consume.
Package configir handles the engine-agnostic NodeConfig IR on the node: canonical ordering, content hashing, diff application and validation into a Plan that the data plane renderers consume.
Package configstore persists the last-known-good (LKG) NodeConfig so the node keeps serving its last applied configuration across restarts, even when the console is unreachable.
Package configstore persists the last-known-good (LKG) NodeConfig so the node keeps serving its last applied configuration across restarts, even when the console is unreachable.
Package controlplane builds Connect clients for the console's node channel (NodeService and ProbeService): CA-pinned clients for enrollment and an mTLS channel with hot-swappable credentials for everything else.
Package controlplane builds Connect clients for the console's node channel (NodeService and ProbeService): CA-pinned clients for enrollment and an mTLS channel with hot-swappable credentials for everything else.
Package dataplane is the agent's client for the OpenResty control API (lua/edgeweir/control.lua), served by nginx on a local unix socket.
Package dataplane is the agent's client for the OpenResty control API (lua/edgeweir/control.lua), served by nginx on a local unix socket.
Package diag is the agent's diagnostics socket: what the running agent knows of its connection to the console, its configuration and its clock (GET /status, JSON) and the Go runtime's profiles (/debug/pprof/).
Package diag is the agent's diagnostics socket: what the running agent knows of its connection to the console, its configuration and its clock (GET /status, JSON) and the Go runtime's profiles (/debug/pprof/).
Package engine controls the OpenResty (nginx) process: configuration tests, reloads and, in managed mode, supervising nginx as a child process of the agent.
Package engine controls the OpenResty (nginx) process: configuration tests, reloads and, in managed mode, supervising nginx as a child process of the agent.
Package enroll implements `edgeweir-node enroll`: it exchanges a single-use token and a locally generated CSR for a node certificate issued by the console's internal CA.
Package enroll implements `edgeweir-node enroll`: it exchanges a single-use token and a locally generated CSR for a node certificate issued by the console's internal CA.
Package extension reads, verifies, packs and signs node extension packages (format edgeweir-node-extension-v1).
Package extension reads, verifies, packs and signs node extension packages (format edgeweir-node-extension-v1).
Package fsutil contains crash-safe file helpers used for all persistent agent state (identity, keys, last-known-good configuration).
Package fsutil contains crash-safe file helpers used for all persistent agent state (identity, keys, last-known-good configuration).
gen
Package geoip serves local MMDBs: the IPinfo Lite database bundled into the release container image at build time, plus operator-provided City / ASN databases.
Package geoip serves local MMDBs: the IPinfo Lite database bundled into the release container image at build time, plus operator-provided City / ASN databases.
check command
Command check fails when the agent would not serve an IPinfo Lite MMDB.
Command check fails when the agent would not serve an IPinfo Lite MMDB.
Package healthcheck runs the active origin health checks (OriginPool.active_health_check, feature active-health-v1).
Package healthcheck runs the active origin health checks (OriginPool.active_health_check, feature active-health-v1).
Package hostinfo collects the NodeInfo reported to the console.
Package hostinfo collects the NodeInfo reported to the console.
Package identity persists the node's enrollment result in the state directory:
Package identity persists the node's enrollment result in the state directory:
Package imageconv converts cached JPEG and PNG responses to WebP and AVIF (ADR-0043).
Package imageconv converts cached JPEG and PNG responses to WebP and AVIF (ADR-0043).
Package mdconv converts HTML responses to Markdown for agents (Markdown for Agents, Site.markdown).
Package mdconv converts HTML responses to Markdown for agents (Markdown for Agents, Site.markdown).
Package metrics measures the host metrics the agent reports with every heartbeat (feature metrics-v1, ReportStatusRequest.metrics):
Package metrics measures the host metrics the agent reports with every heartbeat (feature metrics-v1, ReportStatusRequest.metrics):
Package nft enforces platform bans in the kernel with nftables.
Package nft enforces platform bans in the kernel with nftables.
Package nodelog collects the node's own warnings, errors and events for the console (feature node-logs-v1): the agent's and the supervisor's slog records through Handler, OpenResty's error log through ParseNginx.
Package nodelog collects the node's own warnings, errors and events for the console (feature node-logs-v1): the agent's and the supervisor's slog records through Handler, OpenResty's error log through ParseNginx.
pki
Package pki implements the node side of the console's internal PKI: key and CSR generation, PEM handling, CA pinning during enrollment and the TLS configurations used for the node channel.
Package pki implements the node side of the console's internal PKI: key and CSR generation, PEM handling, CA pinning during enrollment and the TLS configurations used for the node channel.
pkitest
Package pkitest provides a throwaway certificate authority that mimics the console's internal CA.
Package pkitest provides a throwaway certificate authority that mimics the console's internal CA.
Package probe measures, for the console's scheduling, whether the scheduling addresses of edge nodes answer (ProbeService, proto v0.14.0).
Package probe measures, for the console's scheduling, whether the scheduling addresses of edge nodes answer (ProbeService, proto v0.14.0).
Package render produces the OpenResty nginx.conf from a validated plan.
Package render produces the OpenResty nginx.conf from a validated plan.
Package retry calls an operation again after failures that may pass (a data plane that is still starting, a busy lock), with exponential backoff, until it succeeds, fails for good, its budget is spent or its context ends.
Package retry calls an operation again after failures that may pass (a data plane that is still starting, a busy lock), with exponential backoff, until it succeeds, fails for good, its budget is spent or its context ends.
Package sandbox runs the agent's converters' work in limited child processes of the agent's own binary (the WebP / AVIF and Markdown converters, ADR-0043): bounded memory, no files, few descriptors, no capabilities, no_new_privs, killed with the agent.
Package sandbox runs the agent's converters' work in limited child processes of the agent's own binary (the WebP / AVIF and Markdown converters, ADR-0043): bounded memory, no files, few descriptors, no capabilities, no_new_privs, killed with the agent.
Package sidecar starts an extension's sidecar (extension version 1.1, docs/reference/extensions.md in the console repository) in its sandbox: the agent runs `edgeweir-node sidecar-exec` (ChildCommand) with a Spec in the environment; the child moves itself into the sidecar's cgroup, sets the resource limits, switches to the sidecar user, sets no_new_privs and a seccomp filter, and executes the binary with only the Spec's environment.
Package sidecar starts an extension's sidecar (extension version 1.1, docs/reference/extensions.md in the console repository) in its sandbox: the agent runs `edgeweir-node sidecar-exec` (ChildCommand) with a Spec in the environment; the child moves itself into the sidecar's cgroup, sets the resource limits, switches to the sidecar user, sets no_new_privs and a seccomp filter, and executes the binary with only the Spec's environment.
testutil
childproc
Package childproc helps tests that run stand-in processes (a fake OpenResty, the test binary as a node) and wait for what those record.
Package childproc helps tests that run stand-in processes (a fake OpenResty, the test binary as a node) and wait for what those record.
fakeclock
Package fakeclock is a manual clock for tests of code that schedules with callbacks (healthcheck.Clock): time only moves with Advance.
Package fakeclock is a manual clock for tests of code that schedules with callbacks (healthcheck.Clock): time only moves with Advance.
fakeconsole
Package fakeconsole is a minimal in-memory implementation of the console's NodeService and ProbeService (connect-go) used by the integration tests and the container smoke test.
Package fakeconsole is a minimal in-memory implementation of the console's NodeService and ProbeService (connect-go) used by the integration tests and the container smoke test.
fakedataplane
Package fakedataplane serves an in-memory imitation of the Lua control API (lua/edgeweir/control.lua) on a unix socket, for Go tests.
Package fakedataplane serves an in-memory imitation of the Lua control API (lua/edgeweir/control.lua) on a unix socket, for Go tests.
geofixture
Package geofixture creates synthetic MMDBs; it contains no third-party data.
Package geofixture creates synthetic MMDBs; it contains no third-party data.
Package upgrade installs only release artifacts verified against an operator's local trust policy.
Package upgrade installs only release artifacts verified against an operator's local trust policy.
Package version exposes build metadata injected at link time.
Package version exposes build metadata injected at link time.

Jump to

Keyboard shortcuts

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