Documentation
¶
Overview ¶
Package facts implements Ansible's `setup` module / gather_facts: probing a target for a portable subset of system facts (Ansible's own ansible_facts namespace) using only POSIX shell commands present on virtually every real target, no Python required.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Gather ¶
func Gather(ctx context.Context, conn remoteexec.Connection) (map[string]any, error)
Gather probes conn for a portable subset of Ansible's ansible_facts: system/kernel/architecture (uname), hostname/fqdn, distribution/ distribution_version/os_family (parsed /etc/os-release on Linux, sw_vers on macOS), date_time.epoch, processor_count, user_id, and pkg_mgr (the package manager available, for module dispatch).
The returned map's keys are bare (e.g. "system", not "ansible_system") — see vars.InjectFacts for the ansible_facts / ansible_<name> namespacing a caller applies on top.
Types ¶
This section is empty.