Skip to main content
Version: v4.24

list

Shows installed packages.

package::list [format=string]

Description

The package::list operator returns the list of all installed packages.

format = string (optional)

Controls the output format. Valid options are compact and extended.

Defaults to compact.

Schemas

The package::list operator produces two output formats, controlled by the format option:

  • compact: succinct output in a human-readable format
  • extended: verbose output in a machine-readable format

The formats generate the following schemas below.

tenzir.package.compact

The compact format prints the package information according to the following schema:

FieldTypeDescription
idstringThe unique package id.
namestringThe name of this package.
authorstringThe package author.
descriptionstringThe description of this package.
configrecordThe user-provided package configuration

tenzir.package.extended

The extended format is mainly intended for use by non-human consumers, like shell scripts or frontend code. It contains all available information about a package.

FieldTypeDescription
package_definitionrecordThe original package definition object asa found in the library.
resolved_packagerecordThe effective package definition that was produced by applying all inputs and overrides from the config section and removing all disabled pipelines and contexts.
configrecordThe user-provided package configuration.
package_statusrecordRun-time information about the package provided the package manager.

The config object has the following schema, where all fields are optional:

FieldTypeDescription
versionstringThe package version.
sourcerecordThe upstream location of the package definition.
inputsrecordUser-provided values for the package inputs.
overridesrecordUser-provided overrides for fields in the package definition.
metadatarecordAn opaque record that can be set during installation.

The package_status object has the following schema:

FieldTypeDescription
install_statestringThe install state of this package. One of installing, installed, removing or zombie.
from_configurationboolWhether the package was installed from the package add operator or from a configuration file.

Examples

Show all installed packages

package::list
{
  "id": "suricata-ocsf",
  "name": "Suricata OCSF Mappings",
  "author": "Tenzir",
  "description": "[Suricata](https://suricata.io) is an open-source network monitor and\nthreat detection tool.\n\nThis package converts all Suricata events published on the topic `suricata` to\nOCSF and publishes the converted events on the topic `ocsf`.\n",
  "config": {
    "inputs": {},
    "overrides": {}
  }
}

See Also

package::add, package::remove