physical.READERSconstno test imports itconst READERS: readonly ["getent", "id", "stat", "cat", "systemctl", "dpkg-query", "rpm", "pacman", "readlink", "uname"]The programs that observation runs, and no others: every one of them only reads.
Observing a Linux machine with no change: for each requirement, the programs that read what it declares (getent, id, stat, cat, systemctl is-active, systemctl is-enabled, dpkg-query, readlink) are run through the way of running a program that is given (here, over ssh, in a container or on the machine itself), with the prefix that raises rights where there is one, and what they print is read by the shapes of the Logical layer. A resource that is not there has no entry. Observation is by this library and change is by a dialect: nothing here writes.
import { READERS } from "./observe.ts";
READERS.includes("getent"); // truephysical.READERSconstno test imports itconst READERS: readonly ["getent", "id", "stat", "cat", "systemctl", "dpkg-query", "rpm", "pacman", "readlink", "uname"]The programs that observation runs, and no others: every one of them only reads.
physical.observeRequirementsfunctionno test imports itfunction observeRequirements(executor: Executor, requirements: readonly Requirement[], elevate?: readonly string[], family?: "arch" | "debian" | "rhel" | "suse"): Promise<ReadonlyMap<RequirementId, JsonValue>>What is on the machine, in the shape of each requirement's desired state, read with no change: a resource that is not there has no entry.
physical.observePlatformfunctionno test imports itfunction observePlatform(executor: Executor, elevate?: readonly string[]): Promise<Result<Observed, string>>The platform of the machine, read with no change from /etc/os-release and uname -m, or why it is not one Archon knows.
READERSconstconst READERS: readonly ["getent", "id", "stat", "cat", "systemctl", "dpkg-query", "rpm", "pacman", "readlink", "uname"]The programs that observation runs, and no others: every one of them only reads.
observeRequirementsfunctionfunction observeRequirements(executor: Executor, requirements: readonly Requirement[], elevate?: readonly string[], family?: "arch" | "debian" | "rhel" | "suse"): Promise<ReadonlyMap<RequirementId, JsonValue>>What is on the machine, in the shape of each requirement's desired state, read with no change: a resource that is not there has no entry.
observePlatformfunctionfunction observePlatform(executor: Executor, elevate?: readonly string[]): Promise<Result<Observed, string>>The platform of the machine, read with no change from /etc/os-release and uname -m, or why it is not one Archon knows.