Directories
ΒΆ
| Path | Synopsis |
|---|---|
|
Package cmd provides CLI commands for OSAPI.
|
Package cmd provides CLI commands for OSAPI. |
|
internal
|
|
|
agent
Package agent provides the node agent implementation.
|
Package agent provides the node agent implementation. |
|
agent/identity
Package identity provides machine identity resolution for the agent, including machine ID and hostname discovery.
|
Package identity provides machine identity resolution for the agent, including machine ID and hostname discovery. |
|
agent/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
apicontract
Package apicontract reduces an OpenAPI document to its contract: one line for each tag, operation and schema property, sorted.
|
Package apicontract reduces an OpenAPI document to its contract: one line for each tag, operation and schema property, sorted. |
|
area
Package area is the areas that group the operations of osapi: the sections of the UI's Behaviors page and of its list of steps on the Plans page, the folders of the SDK's pages and of the reference pages of the behaviors, the chains and the endpoints, and the sections of the docs site's SDK and Behaviors menus.
|
Package area is the areas that group the operations of osapi: the sections of the UI's Behaviors page and of its list of steps on the Plans page, the folders of the SDK's pages and of the reference pages of the behaviors, the chains and the endpoints, and the sections of the docs site's SDK and Behaviors menus. |
|
atomicfile
Package atomicfile holds filesystem operations shared by providers that write files a running system depends on.
|
Package atomicfile holds filesystem operations shared by providers that write files a running system depends on. |
|
audit
Package audit provides audit logging types and storage.
|
Package audit provides audit logging types and storage. |
|
audit/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
authtoken
Package authtoken provides JWT token generation and validation.
|
Package authtoken provides JWT token generation and validation. |
|
authtoken/gen
command
Package main writes the SDK's constants, authtoken.Go, under --root.
|
Package main writes the SDK's constants, authtoken.Go, under --root. |
|
behavior
Package behavior defines what osapi can do to a host.
|
Package behavior defines what osapi can do to a host. |
|
behavior/behaviortest
Package behaviortest runs a behavior's examples and refusals against a fake host, so a behavior's provider is tested from its definition.
|
Package behaviortest runs a behavior's examples and refusals against a fake host, so a behavior's provider is tested from its definition. |
|
behavior/collectors
Package collectors lists gohai's collectors in the behavior spec, from gohai's own description of them (gohai.Collectors).
|
Package collectors lists gohai's collectors in the behavior spec, from gohai's own description of them (gohai.Collectors). |
|
behavior/command
Package command holds what the generated behavior commands share: flags derived from an input type's tags, and the one table layout every behavior's output renders in, driven by its output type's tags.
|
Package command holds what the generated behavior commands share: flags derived from an input type's tags, and the one table layout every behavior's output renders in, driven by its output type's tags. |
|
behavior/command/commandtest
Package commandtest runs a behavior's generated commands for the gen/cli_public_test.go each one gets, with the SDK call faked.
|
Package commandtest runs a behavior's generated commands for the gen/cli_public_test.go each one gets, with the SDK call faked. |
|
behavior/dispatch
Package dispatch runs a behavior's method for the endpoint layer: it sends the job to the host, or to each host, that the target names, and makes the answer of each host a result row.
|
Package dispatch runs a behavior's method for the endpoint layer: it sends the job to the host, or to each host, that the target names, and makes the answer of each host a result row. |
|
behavior/dispatch/servertest
Package servertest runs the HTTP cases each behavior's generated gen/api_<method>_public_test.go lists.
|
Package servertest runs the HTTP cases each behavior's generated gen/api_<method>_public_test.go lists. |
|
behavior/gen
command
Command gen writes the files built from behaviors.
|
Command gen writes the files built from behaviors. |
|
behavior/gen/group
command
Command group writes what the endpoint layer makes from each behavior's endpoint group: its spec, routes, decoders and commands.
|
Command group writes what the endpoint layer makes from each behavior's endpoint group: its spec, routes, decoders and commands. |
|
behavior/host
Package host is what the agent hands a behavior's provider builder: the platform it runs on and the shared things a provider reaches the host through.
|
Package host is what the agent hands a behavior's provider builder: the platform it runs on and the shared things a provider reaches the host through. |
|
behavior/host/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
behaviors/all
Package all registers every behavior.
|
Package all registers every behavior. |
|
behaviors/all/gen
Package gen imports the generated code of every behavior with an API or a CLI: its commands and its routes.
|
Package gen imports the generated code of every behavior with an API or a CLI: its commands and its routes. |
|
behaviors/certificate
Package certificate is the certificate behavior: the certificate authorities that the host trusts.
|
Package certificate is the certificate behavior: the certificate authorities that the host trusts. |
|
behaviors/certificate/mocks
Package mocks holds the generated double of the certificate provider, for the methods' tests.
|
Package mocks holds the generated double of the certificate provider, for the methods' tests. |
|
behaviors/command
Package command is the command behavior: run a program, or a command line through /bin/sh -c, on the host.
|
Package command is the command behavior: run a program, or a command line through /bin/sh -c, on the host. |
|
behaviors/command/mocks
Package mocks holds the generated double of the command provider, for the methods' tests.
|
Package mocks holds the generated double of the command provider, for the methods' tests. |
|
behaviors/container/docker
Package docker is the docker behavior: the Docker containers of the host.
|
Package docker is the docker behavior: the Docker containers of the host. |
|
behaviors/container/docker/mocks
Package mocks holds the generated double of the docker provider, for the methods' tests.
|
Package mocks holds the generated double of the docker provider, for the methods' tests. |
|
behaviors/container/image
Package image is the image behavior: the Docker images of the host.
|
Package image is the image behavior: the Docker images of the host. |
|
behaviors/container/image/mocks
Package mocks holds the generated double of the image provider, for the methods' tests.
|
Package mocks holds the generated double of the image provider, for the methods' tests. |
|
behaviors/disk
Package disk is the disk behavior: the usage of the host's local filesystems.
|
Package disk is the disk behavior: the usage of the host's local filesystems. |
|
behaviors/disk/mocks
Package mocks holds the generated double of the disk provider, for the methods' tests.
|
Package mocks holds the generated double of the disk provider, for the methods' tests. |
|
behaviors/file
Package file is the file behavior: it deploys the objects of the object store to a host, through the object and managedfile building blocks, and reads how a deployed file is against what osapi wrote.
|
Package file is the file behavior: it deploys the objects of the object store to a host, through the object and managedfile building blocks, and reads how a deployed file is against what osapi wrote. |
|
behaviors/file/mocks
Package mocks holds the generated double of the file provider, for the methods' tests.
|
Package mocks holds the generated double of the file provider, for the methods' tests. |
|
behaviors/group
Package group is the group behavior: the groups of the host.
|
Package group is the group behavior: the groups of the host. |
|
behaviors/group/mocks
Package mocks holds the generated double of the group provider, for the methods' tests.
|
Package mocks holds the generated double of the group provider, for the methods' tests. |
|
behaviors/hostname
Package hostname is the hostname behavior: the name of the host, and on Debian, setting it.
|
Package hostname is the hostname behavior: the name of the host, and on Debian, setting it. |
|
behaviors/hostname/mocks
Package mocks holds the generated double of the hostname provider, for the methods' tests.
|
Package mocks holds the generated double of the hostname provider, for the methods' tests. |
|
behaviors/load
Package load is the load behavior: the load averages of the host.
|
Package load is the load behavior: the load averages of the host. |
|
behaviors/load/mocks
Package mocks holds the generated double of the load provider, for the methods' tests.
|
Package mocks holds the generated double of the load provider, for the methods' tests. |
|
behaviors/log/entry
Package entry is the log behavior: the entries of the systemd journal of the host, read with journalctl on each Linux host.
|
Package entry is the log behavior: the entries of the systemd journal of the host, read with journalctl on each Linux host. |
|
behaviors/log/entry/mocks
Package mocks holds the generated double of the entry provider, for the methods' tests.
|
Package mocks holds the generated double of the entry provider, for the methods' tests. |
|
behaviors/log/source
Package source is the source behavior: the syslog identifiers that wrote to the systemd journal of the host, read with journalctl on each Linux host.
|
Package source is the source behavior: the syslog identifiers that wrote to the systemd journal of the host, read with journalctl on each Linux host. |
|
behaviors/log/source/mocks
Package mocks holds the generated double of the source provider, for the methods' tests.
|
Package mocks holds the generated double of the source provider, for the methods' tests. |
|
behaviors/managedfile
Package managedfile is the managedfile behavior: files osapi writes on a host and keeps a record of, so it can tell its own files from the rest, leave a file alone when it already holds what was asked, and stop managing one.
|
Package managedfile is the managedfile behavior: files osapi writes on a host and keeps a record of, so it can tell its own files from the rest, leave a file alone when it already holds what was asked, and stop managing one. |
|
behaviors/managedfile/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
behaviors/memory
Package memory is the memory behavior: the memory of the host, in bytes.
|
Package memory is the memory behavior: the memory of the host, in bytes. |
|
behaviors/memory/mocks
Package mocks holds the generated double of the memory provider, for the methods' tests.
|
Package mocks holds the generated double of the memory provider, for the methods' tests. |
|
behaviors/netplan
Package netplan is the netplan behavior: the netplan files that osapi writes, validated and applied.
|
Package netplan is the netplan behavior: the netplan files that osapi writes, validated and applied. |
|
behaviors/netplan/mocks
Package mocks holds the generated double of the netplan provider, for the methods' tests.
|
Package mocks holds the generated double of the netplan provider, for the methods' tests. |
|
behaviors/network/connectivity
Package connectivity is the connectivity behavior: whether the host reaches an address, by ICMP ping.
|
Package connectivity is the connectivity behavior: whether the host reaches an address, by ICMP ping. |
|
behaviors/network/connectivity/mocks
Package mocks holds the generated double of the connectivity provider, for the methods' tests.
|
Package mocks holds the generated double of the connectivity provider, for the methods' tests. |
|
behaviors/network/dns
Package dns is the dns behavior: the DNS resolvers of each interface of the host.
|
Package dns is the dns behavior: the DNS resolvers of each interface of the host. |
|
behaviors/network/dns/mocks
Package mocks holds the generated double of the dns provider, for the methods' tests.
|
Package mocks holds the generated double of the dns provider, for the methods' tests. |
|
behaviors/network/iface
Package iface is the interface behavior: the network interfaces of the host.
|
Package iface is the interface behavior: the network interfaces of the host. |
|
behaviors/network/iface/mocks
Package mocks holds the generated double of the interface provider, for the methods' tests.
|
Package mocks holds the generated double of the interface provider, for the methods' tests. |
|
behaviors/network/route
Package route is the route behavior: the routes of an interface.
|
Package route is the route behavior: the routes of an interface. |
|
behaviors/network/route/mocks
Package mocks holds the generated double of the route provider, for the methods' tests.
|
Package mocks holds the generated double of the route provider, for the methods' tests. |
|
behaviors/ntp
Package ntp is the ntp behavior: the NTP servers that chrony uses, and its sync status.
|
Package ntp is the ntp behavior: the NTP servers that chrony uses, and its sync status. |
|
behaviors/ntp/mocks
Package mocks holds the generated double of the ntp provider, for the methods' tests.
|
Package mocks holds the generated double of the ntp provider, for the methods' tests. |
|
behaviors/object
Package object is the object behavior: the objects of the Object Store of the fleet, which other behaviors read, such as the content of a file.
|
Package object is the object behavior: the objects of the Object Store of the fleet, which other behaviors read, such as the content of a file. |
|
behaviors/object/mocks
Package mocks holds the generated double of the object provider, for the methods' tests.
|
Package mocks holds the generated double of the object provider, for the methods' tests. |
|
behaviors/os
Package os is the os behavior: the operating system of the host, its distribution and version.
|
Package os is the os behavior: the operating system of the host, its distribution and version. |
|
behaviors/os/mocks
Package mocks holds the generated double of the os provider, for the methods' tests.
|
Package mocks holds the generated double of the os provider, for the methods' tests. |
|
behaviors/packages
Package packages is the package behavior: the packages installed on the host.
|
Package packages is the package behavior: the packages installed on the host. |
|
behaviors/packages/mocks
Package mocks holds the generated double of the package provider, for the methods' tests.
|
Package mocks holds the generated double of the package provider, for the methods' tests. |
|
behaviors/password
Package password is the password behavior: the password of a user, under the user.
|
Package password is the password behavior: the password of a user, under the user. |
|
behaviors/password/mocks
Package mocks holds the generated double of the password provider, for the methods' tests.
|
Package mocks holds the generated double of the password provider, for the methods' tests. |
|
behaviors/power
Package power is the power behavior: reboot or shut down the host.
|
Package power is the power behavior: reboot or shut down the host. |
|
behaviors/power/mocks
Package mocks holds the generated double of the power provider, for the methods' tests.
|
Package mocks holds the generated double of the power provider, for the methods' tests. |
|
behaviors/process
Package process is the process behavior: the processes of the host.
|
Package process is the process behavior: the processes of the host. |
|
behaviors/process/mocks
Package mocks holds the generated double of the process provider, for the methods' tests.
|
Package mocks holds the generated double of the process provider, for the methods' tests. |
|
behaviors/schedule
Package schedule is the schedule behavior: the cron entries that osapi deploys.
|
Package schedule is the schedule behavior: the cron entries that osapi deploys. |
|
behaviors/schedule/mocks
Package mocks holds the generated double of the group provider, for the methods' tests.
|
Package mocks holds the generated double of the group provider, for the methods' tests. |
|
behaviors/service
Package service is the service behavior: the services of the host, systemd on Linux and launchd on macOS.
|
Package service is the service behavior: the services of the host, systemd on Linux and launchd on macOS. |
|
behaviors/service/mocks
Package mocks holds the generated double of the service provider, for the methods' tests.
|
Package mocks holds the generated double of the service provider, for the methods' tests. |
|
behaviors/sshkey
Package sshkey is the sshkey behavior: the authorized SSH keys of a user.
|
Package sshkey is the sshkey behavior: the authorized SSH keys of a user. |
|
behaviors/sshkey/mocks
Package mocks holds the generated double of the sshkey provider, for the methods' tests.
|
Package mocks holds the generated double of the sshkey provider, for the methods' tests. |
|
behaviors/status
Package status is the status behavior: the status summary of a node.
|
Package status is the status behavior: the status summary of a node. |
|
behaviors/status/mocks
Package mocks holds the generated double of the status provider, for the methods' tests.
|
Package mocks holds the generated double of the status provider, for the methods' tests. |
|
behaviors/sysctl
Package sysctl is the sysctl behavior: kernel parameters osapi writes to /etc/sysctl.d and applies.
|
Package sysctl is the sysctl behavior: kernel parameters osapi writes to /etc/sysctl.d and applies. |
|
behaviors/sysctl/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
behaviors/timezone
Package timezone is the timezone behavior: the timezone of the host.
|
Package timezone is the timezone behavior: the timezone of the host. |
|
behaviors/timezone/mocks
Package mocks holds the generated double of the timezone provider, for the methods' tests.
|
Package mocks holds the generated double of the timezone provider, for the methods' tests. |
|
behaviors/updatepackages
Package updatepackages is the updates behavior: the updates that the package index has for the host.
|
Package updatepackages is the updates behavior: the updates that the package index has for the host. |
|
behaviors/updatepackages/mocks
Package mocks holds the generated double of the updatepackages provider, for the methods' tests.
|
Package mocks holds the generated double of the updatepackages provider, for the methods' tests. |
|
behaviors/uptime
Package uptime is the uptime behavior: how long the host has run since it booted.
|
Package uptime is the uptime behavior: how long the host has run since it booted. |
|
behaviors/uptime/mocks
Package mocks holds the generated double of the uptime provider, for the methods' tests.
|
Package mocks holds the generated double of the uptime provider, for the methods' tests. |
|
behaviors/user
Package user is the user behavior: the accounts of the host.
|
Package user is the user behavior: the accounts of the host. |
|
behaviors/user/mocks
Package mocks holds the generated double of the user provider, for the methods' tests.
|
Package mocks holds the generated double of the user provider, for the methods' tests. |
|
bus
Package bus builds the NATS options, buckets and streams that osapi uses.
|
Package bus builds the NATS options, buckets and streams that osapi uses. |
|
bus/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
bus/server
Package server runs the embedded NATS server that osapi starts for itself, and writes its heartbeat.
|
Package server runs the embedded NATS server that osapi starts for itself, and writes its heartbeat. |
|
cli
Package cli holds what the commands of the CLI share: the printer, the theme, the tables and the help.
|
Package cli holds what the commands of the CLI share: the printer, the theme, the tables and the help. |
|
cli/command
Package command is the command layer of the CLI, and the DSL of its local commands.
|
Package command is the command layer of the CLI, and the DSL of its local commands. |
|
cli/command/gen
Package commandgen writes the cobra commands of a group of the command layer, gen/cli.go: one command for each method, with its help, its flags and its examples, for the local generator, the endpoint generator and the behavior generator alike.
|
Package commandgen writes the cobra commands of a group of the command layer, gen/cli.go: one command for each method, with its help, its flags and its examples, for the local generator, the endpoint generator and the behavior generator alike. |
|
cli/command/gen/generate
command
Command generate writes the files that come from the local groups: for each group, the cobra commands in gen/cli.go, and internal/cli/commands/all/gen, which registers every group's commands.
|
Command generate writes the files that come from the local groups: for each group, the cobra commands in gen/cli.go, and internal/cli/commands/all/gen, which registers every group's commands. |
|
cli/command/gen/genfile
Package genfile writes generated files for the local, endpoint and behavior generators alike: it removes the files a run made before, writes each file under the repository's root, and groups a Go file's imports as the repository does.
|
Package genfile writes generated files for the local, endpoint and behavior generators alike: it removes the files a run made before, writes each file under the repository's root, and groups a Go file's imports as the repository does. |
|
cli/command/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
cli/commands/agentcmd
Package agentcmd is the agent group: osapi agent start, which runs the agent on a managed host.
|
Package agentcmd is the agent group: osapi agent start, which runs the agent on a managed host. |
|
cli/commands/agentcmd/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
cli/commands/agentservice
Package agentservice installs the agent of this host as a service that starts at boot: a systemd unit on Linux, a launch daemon on macOS, with a config that has the join string.
|
Package agentservice installs the agent of this host as a service that starts at boot: a systemd unit on Linux, a launch daemon on macOS, with a config that has the join string. |
|
cli/commands/all
Package all registers every local group, one blank import each.
|
Package all registers every local group, one blank import each. |
|
cli/commands/all/gen
Package gen registers the commands of every local group.
|
Package gen registers the commands of every local group. |
|
cli/commands/behaviordsl
Package behaviordsl is the behavior group: the commands that list, describe, scaffold, teach and check the behaviors of this binary.
|
Package behaviordsl is the behavior group: the commands that list, describe, scaffold, teach and check the behaviors of this binary. |
|
cli/commands/chain
Package chain is the chain group of commands, osapi dsl chain: the behaviors that a behavior calls on the same host, in the same job.
|
Package chain is the chain group of commands, osapi dsl chain: the behaviors that a behavior calls on the same host, in the same job. |
|
cli/commands/clidocs
Package clidocs is the docs group under osapi dsl: osapi dsl docs generate, which writes the generated pages of the docs site.
|
Package clidocs is the docs group under osapi dsl: osapi dsl docs generate, which writes the generated pages of the docs site. |
|
cli/commands/commanddsl
Package commanddsl is the command group under osapi cli: the commands that list, describe, scaffold, teach and check the local groups of the command DSL.
|
Package commanddsl is the command group under osapi cli: the commands that list, describe, scaffold, teach and check the local groups of the command DSL. |
|
cli/commands/config
Package config is the config group: osapi config list, get and validate, which read osapi's settings the way osapi start does.
|
Package config is the config group: osapi config list, get and validate, which read osapi's settings the way osapi start does. |
|
cli/commands/controllercmd
Package controllercmd is the controller group: osapi controller start, which runs the REST API.
|
Package controllercmd is the controller group: osapi controller start, which runs the REST API. |
|
cli/commands/controllercmd/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
cli/commands/endpointdsl
Package endpointdsl is the endpoint group under osapi controller: the commands that list, describe, scaffold, teach and check the endpoint groups of the controller.
|
Package endpointdsl is the endpoint group under osapi controller: the commands that list, describe, scaffold, teach and check the endpoint groups of the controller. |
|
cli/commands/join
Package join is the join group under osapi controller: osapi controller join token create, list and revoke, which make, show and remove the tokens that admit an agent at its join (osapi-io/osapi#1313).
|
Package join is the join group under osapi controller: osapi controller join token create, list and revoke, which make, show and remove the tokens that admit an agent at its join (osapi-io/osapi#1313). |
|
cli/commands/natsauth
Package natsauth is the auth group under osapi nats: osapi nats auth password create and operator create, which make the authentication of a NATS setup for osapi, with a credential for each osapi role (osapi-io/osapi#1420).
|
Package natsauth is the auth group under osapi nats: osapi nats auth password create and operator create, which make the authentication of a NATS setup for osapi, with a credential for each osapi role (osapi-io/osapi#1420). |
|
cli/commands/natsperms
Package natsperms is the permissions group under osapi nats: osapi nats permissions get, which prints the NATS subjects that one osapi process needs, for a NATS server that osapi does not run (osapi-io/osapi#1415).
|
Package natsperms is the permissions group under osapi nats: osapi nats permissions get, which prints the NATS subjects that one osapi process needs, for a NATS server that osapi does not run (osapi-io/osapi#1415). |
|
cli/commands/natsserver
Package natsserver is the flat group under osapi nats: osapi nats start, which runs the embedded NATS server as its own process.
|
Package natsserver is the flat group under osapi nats: osapi nats start, which runs the embedded NATS server as its own process. |
|
cli/commands/natsserver/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
cli/commands/natssetup
Package natssetup is the setup group under osapi nats: osapi nats setup, which creates osapi's streams and buckets on a NATS server that osapi does not run, such as an existing cluster.
|
Package natssetup is the setup group under osapi nats: osapi nats setup, which creates osapi's streams and buckets on a NATS server that osapi does not run, such as an existing cluster. |
|
cli/commands/pkicert
Package pkicert is osapi pki cert: it shows and rotates the TLS certificates that the servers of osapi serve on this host, the self-signed ones that each makes at its first start and a cert_file of the operator.
|
Package pkicert is osapi pki cert: it shows and rotates the TLS certificates that the servers of osapi serve on this host, the self-signed ones that each makes at its first start and a cert_file of the operator. |
|
cli/commands/pkikey
Package pkikey is the key group under osapi pki: osapi pki key list, get, create and rotate, which read, make and rotate the keys of osapi on this host.
|
Package pkikey is the key group under osapi pki: osapi pki key list, get, create and rotate, which read, make and rotate the keys of osapi on this host. |
|
cli/commands/pkilist
Package pkilist is osapi pki list: each key and each certificate of osapi on this host, in one list.
|
Package pkilist is osapi pki list: each key and each certificate of osapi on this host, in one list. |
|
cli/commands/role
Package role is the role group of local commands: osapi controller role list and get, which read the built-in roles and the custom roles of the controller's config, with what each grants.
|
Package role is the role group of local commands: osapi controller role list and get, which read the built-in roles and the custom roles of the controller's config, with what each grants. |
|
cli/commands/role/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
cli/commands/sdk
Package sdk is the sdk group: osapi sdk list, get, spec get and validate, which describe and check the Go SDK in this binary, as each DSL's group does and as osapi agent collector does for gohai's collectors.
|
Package sdk is the sdk group: osapi sdk list, get, spec get and validate, which describe and check the Go SDK in this binary, as each DSL's group does and as osapi agent collector does for gohai's collectors. |
|
cli/commands/skill
Package skill is the skill group: osapi skill list and get, which show the agent skills that this binary has, and osapi skill install, which installs them into a repository.
|
Package skill is the skill group: osapi skill list and get, which show the agent skills that this binary has, and osapi skill install, which installs them into a repository. |
|
cli/commands/startcmd
Package startcmd is the start group: osapi start, which runs the NATS server, the controller and the agent in one process.
|
Package startcmd is the start group: osapi start, which runs the NATS server, the controller and the agent in one process. |
|
cli/commands/token
Package token is the token group of local commands: osapi controller token generate and validate, which sign and read the bearer tokens of the API with the signing key of the controller's config.
|
Package token is the token group of local commands: osapi controller token generate and validate, which sign and read the bearer tokens of the API with the signing key of the controller's config. |
|
cli/commands/token/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
cli/commands/version
Package version is the version group: osapi version, which prints the build of the binary.
|
Package version is the version group: osapi version, which prints the build of the binary. |
|
cli/gen
command
Command gen writes the docs site's palette from the CLI's colors.
|
Command gen writes the docs site's palette from the CLI's colors. |
|
cli/reference
Package reference writes the CLI reference pages of the docs site from the cobra command tree.
|
Package reference writes the CLI reference pages of the docs site from the cobra command tree. |
|
config
Package config provides configuration types and validation for OSAPI.
|
Package config provides configuration types and validation for OSAPI. |
|
controller
Package controller runs the controller process: the REST API, and the watchers and the heartbeat that run beside it.
|
Package controller runs the controller process: the REST API, and the watchers and the heartbeat that run beside it. |
|
controller/admission
Package admission is the controller side of admission: it receives an agent's request over NATS, and admits, rejects or revokes its key.
|
Package admission is the controller side of admission: it receives an agent's request over NATS, and admits, rejects or revokes its key. |
|
controller/admission/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/api
Package api provides the REST API server and handler registration.
|
Package api provides the REST API server and handler registration. |
|
controller/api/apierr
Package apierr answers, in one place, which HTTP status a failed job deserves.
|
Package apierr answers, in one place, which HTTP status a failed job deserves. |
|
controller/api/ui
Package ui provides the HTTP handler for serving the embedded React UI.
|
Package ui provides the HTTP handler for serving the embedded React UI. |
|
controller/certrotation
Package certrotation rotates the NATS server's self-signed certificate with no restart and no new join of the agents.
|
Package certrotation rotates the NATS server's self-signed certificate with no restart and no new join of the agents. |
|
controller/certrotation/mocks
Package mocks holds the generated doubles of the dependencies of the rotation of the NATS server's certificate, for its tests.
|
Package mocks holds the generated doubles of the dependencies of the rotation of the NATS server's certificate, for its tests. |
|
controller/endpoint
Package endpoint is the DSL for the controller's own API: the operations that run on the controller, such as the agents, the jobs and the audit log, and not on a host.
|
Package endpoint is the DSL for the controller's own API: the operations that run on the controller, such as the agents, the jobs and the audit log, and not on a host. |
|
controller/endpoint/command
Package command is the endpoint layer's runner of the generated CLI commands of the endpoint groups.
|
Package command is the endpoint layer's runner of the generated CLI commands of the endpoint groups. |
|
controller/endpoint/gen
command
Command gen writes the files that come from the endpoint groups: for each group that Uses a type, its gen/api.yaml, the routes in gen/api.go and the decoders in gen/decode.go, and internal/controller/endpoints/all/gen, which registers every group's routes.
|
Command gen writes the files that come from the endpoint groups: for each group that Uses a type, its gen/api.yaml, the routes in gen/api.go and the decoders in gen/decode.go, and internal/controller/endpoints/all/gen, which registers every group's routes. |
|
controller/endpoint/gen/genutil
Package genutil holds what the endpoint layer's writers share: the fields of an input as JSON reads them, and the house layout of a jen group.
|
Package genutil holds what the endpoint layer's writers share: the fields of an input as JSON reads them, and the house layout of a jen group. |
|
controller/endpoint/gen/routegen
Package routegen writes the route table and the decoders of an endpoint group, for the endpoint generator and the behavior generator alike, so a behavior's routes are the same code as an endpoint's.
|
Package routegen writes the route table and the decoders of an endpoint group, for the endpoint generator and the behavior generator alike, so a behavior's routes are the same code as an endpoint's. |
|
controller/endpoint/gen/specgen
Package specgen writes the specs as the repository keeps them, for the endpoint generator and the behavior generator alike: the spec of each group, and the full spec of the API, which joins them.
|
Package specgen writes the specs as the repository keeps them, for the endpoint generator and the behavior generator alike: the spec of each group, and the full spec of the API, which joins them. |
|
controller/endpoint/server
Package server is the runtime the generated routes of an endpoint group call.
|
Package server is the runtime the generated routes of an endpoint group call. |
|
controller/endpoints/admission
Package admission is the endpoint group for admission: the nodes that ask to join, the nodes osapi has admitted, and the decisions against nodes.
|
Package admission is the endpoint group for admission: the nodes that ask to join, the nodes osapi has admitted, and the decisions against nodes. |
|
controller/endpoints/admission/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/endpoints/agent
Package agent is the endpoint group for the agents of the fleet: the agents that report, and the actions on one agent.
|
Package agent is the endpoint group for the agents of the fleet: the agents that report, and the actions on one agent. |
|
controller/endpoints/agent/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/endpoints/all
Package all registers every endpoint group, one blank import each.
|
Package all registers every endpoint group, one blank import each. |
|
controller/endpoints/all/gen
Package gen registers the routes of every endpoint group that is served.
|
Package gen registers the routes of every endpoint group that is served. |
|
controller/endpoints/audit
Package audit is the endpoint group for the audit log: the record of each request the controller served.
|
Package audit is the endpoint group for the audit log: the record of each request the controller served. |
|
controller/endpoints/audit/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/endpoints/catalog
Package catalog is the catalog endpoint group: what the UI reads from the controller after sign-in.
|
Package catalog is the catalog endpoint group: what the UI reads from the controller after sign-in. |
|
controller/endpoints/file
Package file is the endpoint group for the files in the Object Store: what a deploy writes to a host.
|
Package file is the endpoint group for the files in the Object Store: what a deploy writes to a host. |
|
controller/endpoints/file/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/endpoints/health
Package health is the endpoint group for the controller's health: the liveness and readiness probes, and the status of each component.
|
Package health is the endpoint group for the controller's health: the liveness and readiness probes, and the status of each component. |
|
controller/endpoints/health/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/endpoints/job
Package job is the endpoint group for the job queue: the jobs the controller sent to the agents.
|
Package job is the endpoint group for the job queue: the jobs the controller sent to the agents. |
|
controller/endpoints/job/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/endpoints/pki
Package pki is the pki endpoint group: the certificates of the fleet, the controller's and each agent's, through the API.
|
Package pki is the pki endpoint group: the certificates of the fleet, the controller's and each agent's, through the API. |
|
controller/endpoints/pki/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/endpoints/secret
Package secret is the endpoint group of the secrets in the vaults of the controller: the vaults, the metadata of each key, and a write of a value.
|
Package secret is the endpoint group of the secrets in the vaults of the controller: the vaults, the metadata of each key, and a write of a value. |
|
controller/endpoints/secret/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/endpoints/telemetry
Package telemetry is the endpoint group for what the controller reads from the telemetry backends, such as the spans of a trace.
|
Package telemetry is the endpoint group for what the controller reads from the telemetry backends, such as the spans of a trace. |
|
controller/endpoints/telemetry/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/health
Package health provides health check API handlers.
|
Package health provides health check API handlers. |
|
controller/health/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
controller/jointoken
Package jointoken is the store of join tokens: a token that admits an agent at its join (osapi-io/osapi#1313).
|
Package jointoken is the store of join tokens: a token that admits an agent at its join (osapi-io/osapi#1313). |
|
controller/keyrotation
Package keyrotation rotates the controller's key with no new admission of the agents.
|
Package keyrotation rotates the controller's key with no new admission of the agents. |
|
controller/keyrotation/mocks
Package mocks holds the generated doubles of the dependencies of the rotation of the controller's key, for its tests.
|
Package mocks holds the generated doubles of the dependencies of the rotation of the controller's key, for its tests. |
|
controller/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
controller/notify
Package notify provides a pluggable condition notification system that watches the registry KV bucket for component condition transitions and dispatches events via configurable notifiers.
|
Package notify provides a pluggable condition notification system that watches the registry KV bucket for component condition transitions and dispatches events via configurable notifiers. |
|
controller/notify/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
dsl
Package dsl is the list of osapi's DSLs: the behavior DSL, the chain rules, the endpoint DSL and the command DSL.
|
Package dsl is the list of osapi's DSLs: the behavior DSL, the chain rules, the endpoint DSL and the command DSL. |
|
dslcheck
Package dslcheck holds the tests that guard the three DSLs: the behavior DSL, the endpoint DSL and the command DSL.
|
Package dslcheck holds the tests that guard the three DSLs: the behavior DSL, the endpoint DSL and the command DSL. |
|
exec
Package exec provides command execution utilities.
|
Package exec provides command execution utilities. |
|
exec/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
facts
Package facts provides shared fact key constants and validation for @fact.
|
Package facts provides shared fact key constants and validation for @fact. |
|
guide
Package guide holds what a command group tells an author, or an agent, about how to build for it: the terms of its DSL or format, and the rules that its validate command applies, each with its fix.
|
Package guide holds what a command group tells an author, or an agent, about how to build for it: the terms of its DSL or format, and the rules that its validate command applies, each with its fix. |
|
guide/sdktypes
Package sdktypes lists the closed sets of pkg/sdk/types in a spec, from the SDK's own description of them (types.All), as package collectors lists gohai's collectors.
|
Package sdktypes lists the closed sets of pkg/sdk/types in a spec, from the SDK's own description of them (types.All), as package collectors lists gohai's collectors. |
|
heartbeat
Package heartbeat writes the registration of a component that is not an agent, for example the controller or the NATS server, to the registry KV bucket.
|
Package heartbeat writes the registration of a component that is not an agent, for example the controller or the NATS server, to the registry KV bucket. |
|
heartbeat/mocks
Package mocks holds the generated doubles of the interfaces of package heartbeat, for its tests.
|
Package mocks holds the generated doubles of the interfaces of package heartbeat, for its tests. |
|
initsys
Package initsys is how osapi runs a program as a service under the service manager of a host: systemd on Linux and launchd on macOS.
|
Package initsys is how osapi runs a program as a service under the service manager of a host: systemd on Linux and launchd on macOS. |
|
job
Package job provides NATS subject hierarchy for distributed job routing.
|
Package job provides NATS subject hierarchy for distributed job routing. |
|
job/client
Package client provides job client operations for NATS JetStream.
|
Package client provides job client operations for NATS JetStream. |
|
job/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
job/mocks/hostname
Package hostname provides mock implementations for HostnameProvider testing.
|
Package hostname provides mock implementations for HostnameProvider testing. |
|
natsauth
Package natsauth makes the authentication of a NATS setup for osapi: a credential for each osapi role, with the least permissions of the role, and the server's part.
|
Package natsauth makes the authentication of a NATS setup for osapi: a credential for each osapi role, with the least permissions of the role, and the server's part. |
|
natscallout
Package natscallout is osapi's NATS auth callout service.
|
Package natscallout is osapi's NATS auth callout service. |
|
natsjwt
Package natsjwt mints the NATS user JWTs of osapi in operator mode: the bootstrap user of a join token, and the user of an agent that joined.
|
Package natsjwt mints the NATS user JWTs of osapi in operator mode: the bootstrap user of a join token, and the user of an agent that joined. |
|
password
Package password hashes a plain password into the form that /etc/shadow and chpasswd -e take, on the controller.
|
Package password hashes a plain password into the form that /etc/shadow and chpasswd -e take, on the controller. |
|
pki
Package pki provides Ed25519 keypair management for agent identity, including generation, loading, saving, signing, and verification.
|
Package pki provides Ed25519 keypair management for agent identity, including generation, loading, saving, signing, and verification. |
|
provider
Package provider defines shared types for all provider implementations.
|
Package provider defines shared types for all provider implementations. |
|
provider/gohaitest
Package gohaitest builds a fake host for the tests of the providers that read through gohai: a filesystem with given files, and gohai's generated command runner, configured to answer given command lines.
|
Package gohaitest builds a fake host for the tests of the providers that read through gohai: a filesystem with given files, and gohai's generated command runner, configured to answer given command lines. |
|
provider/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
|
provider/node/disk
Package disk reads the local disks of the host through gohai.
|
Package disk reads the local disks of the host through gohai. |
|
provider/node/disk/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
provider/node/host
Package host reads the facts of the host, such as its hostname, its OS and its uptime.
|
Package host reads the facts of the host, such as its hostname, its OS and its uptime. |
|
provider/node/host/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
provider/node/load
Package load reads the load averages of the host.
|
Package load reads the load averages of the host. |
|
provider/node/load/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
provider/node/memory
Package memory reads the memory of the host.
|
Package memory reads the memory of the host. |
|
provider/node/memory/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
sdk/gen
command
Command gen writes the typed services of the Go SDK, pkg/sdk/client, from the full spec of the API, internal/controller/api/gen/api.yaml.
|
Command gen writes the typed services of the Go SDK, pkg/sdk/client, from the full spec of the API, internal/controller/api/gen/api.yaml. |
|
sdk/gen/sdkmodel
Package sdkmodel is what the Go SDK is made of, read from the full spec of the API: each service, its methods with their parameters, body and result, and each type the methods send and receive.
|
Package sdkmodel is what the Go SDK is made of, read from the full spec of the API: each service, its methods with their parameters, body and result, and each type the methods send and receive. |
|
sdk/sdkspec
Package sdkspec is the Go SDK as data: its spec, which osapi sdk spec get prints and the SDK skill is made from, and its checks, which osapi sdk validate runs.
|
Package sdkspec is the Go SDK as data: its spec, which osapi sdk spec get prints and the SDK skill is made from, and its checks, which osapi sdk validate runs. |
|
secret
Package secret has the type of a secret in the three DSLs: Value, a reference, secret://<vault>/<key>, or a literal value.
|
Package secret has the type of a secret in the three DSLs: Value, a reference, secret://<vault>/<key>, or a literal value. |
|
secret/seal
Package seal keeps the secret values of a job from each reader but its target agents.
|
Package seal keeps the secret values of a job from each reader but its target agents. |
|
secret/vault
Package vault is the store of secrets that the controller resolves a secret://<vault>/<key> reference from.
|
Package vault is the store of secrets that the controller resolves a secret://<vault>/<key> reference from. |
|
secret/vault/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
secret/vault/natsvault
Package natsvault is the nats type of vault, the one that osapi ships.
|
Package natsvault is the nats type of vault, the one that osapi ships. |
|
secret/vault/natsvault/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
settings
Package settings is the registry of who owns each section of osapi's config and its defaults.
|
Package settings is the registry of who owns each section of osapi's config and its defaults. |
|
skills
Package skills writes the skills compiled into osapi into a repository, for the agent tools that read them.
|
Package skills writes the skills compiled into osapi into a repository, for the agent tools that read them. |
|
telemetry/httplog
Package httplog logs one line per HTTP request through the application's slog.Logger.
|
Package httplog logs one line per HTTP request through the application's slog.Logger. |
|
telemetry/instruments
Package instruments is each metric that osapi records: its name, kind, unit, labels, the component that records it, and its doc.
|
Package instruments is each metric that osapi records: its name, kind, unit, labels, the component that records it, and its doc. |
|
telemetry/metrics
Package metrics provides a lightweight HTTP server for per-component Prometheus metrics with isolated registries.
|
Package metrics provides a lightweight HTTP server for per-component Prometheus metrics with isolated registries. |
|
telemetry/opspan
Package opspan opens the span of one operation of a store or a client, such as job.list or audit.get.
|
Package opspan opens the span of one operation of a store or a client, such as job.list or audit.get. |
|
telemetry/process
Package process collects the metrics of the osapi process, and the conditions that its limits give, such as high memory.
|
Package process collects the metrics of the osapi process, and the conditions that its limits give, such as high memory. |
|
telemetry/process/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
telemetry/respspan
Package respspan times what the controller does after a handler has its answer, as two spans of their own under the request: response.encode, the encode of the answer as JSON, and response.write, the write of it to the client, which waits on the network.
|
Package respspan times what the controller does after a handler has its answer, as two spans of their own under the request: response.encode, the encode of the answer as JSON, and response.write, the write of it to the client, which waits on the network. |
|
telemetry/traces
Package traces reads the spans of a trace from a tracing backend, so that osapi can show a trace without the caller reaching the backend.
|
Package traces reads the spans of a trace from a tracing backend, so that osapi can show a trace without the caller reaching the backend. |
|
telemetry/tracing
Package tracing provides OpenTelemetry tracing initialization and helpers.
|
Package tracing provides OpenTelemetry tracing initialization and helpers. |
|
templates
Package templates holds the system templates of osapi, which the controller keeps in the Object Store under osapi/.
|
Package templates holds the system templates of osapi, which the controller keeps in the Object Store under osapi/. |
|
templates/mocks
Package mocks provides mock implementations for testing.
|
Package mocks provides mock implementations for testing. |
|
validation
Package validation provides a shared validator instance.
|
Package validation provides a shared validator instance. |
|
validation/rule
Package rule is what a validate tag means in a spec.
|
Package rule is what a validate tag means in a spec. |
|
pkg
|
|
|
sdk/client
Package client is the Go SDK of the OSAPI REST API.
|
Package client is the Go SDK of the OSAPI REST API. |
|
sdk/types
Package types holds the types that the API, the SDK and the CLI share, such as the states of an agent and the roles of a token.
|
Package types holds the types that the API, the SDK and the CLI share, such as the states of an agent and the roles of a token. |
|
Package ui provides the embedded React management dashboard assets.
|
Package ui provides the embedded React management dashboard assets. |
Click to show internal directories.
Click to hide internal directories.