Landscape Outbox configuration reference¶
The Landscape Outbox service is configured entirely through environment variables. There is no separate configuration file format; all settings are expressed as environment variables, which can be supplied directly or through the snap configuration system.
The outbox snap (landscape-outbox) provides two services:
landscape-outbox.outbox: the main outbox daemon that reads pending entries from the database and publishes them to downstream systems.landscape-outbox.cleanup: a periodic cleanup job that purges old outbox entries from the database.
Each service has its own set of environment variables, described in the sections below.
service.conf integration¶
The outbox needs to use the same database and broker systems that Landscape server uses. By default, the outbox will read all necessary database and broker configurations from /etc/landscape/service.conf and will populate the corresponding environment variables. The path to the service.conf file can be overridden via the LANDSCAPE_CONFIG_FILE environment variable or equivalently the landscape.service-conf-file snap key.
This means that several environment variables marked as required in this reference do not need to be set directly and can instead be read from the service.conf. These configurations are marked with service.conf-supplied: Yes. It is recommended to use this integration instead of setting these environment variables directly.
The table below lists every environment variable that is populated. Note that all three databases share the same host, port, user, password, and SSL settings from the [stores] section.
Environment variable |
|
|
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
landscape-outbox.outbox service¶
Database settings¶
The outbox service connects to three PostgreSQL databases. Each database is configured with the same set of keys; replace <DB> below with MAIN, ACCOUNT, or RESOURCE when setting the environment variable. Replace <db> with main, account, or resource when setting the snap key. Note that environment variables and snap keys are case-sensitive.
LANDSCAPE_DATABASE_<DB>_NAME¶
Purpose: The PostgreSQL database name to connect to.
Snap key:
landscape.database.<db>.nameDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_DATABASE_<DB>_HOST¶
Purpose: The hostname or IP address of the PostgreSQL server.
Snap key:
landscape.database.<db>.hostDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_DATABASE_<DB>_PORT¶
Purpose: The port on which the PostgreSQL server is listening.
Snap key:
landscape.database.<db>.portDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_DATABASE_<DB>_USER¶
Purpose: The username used to authenticate with the PostgreSQL server.
Snap key:
landscape.database.<db>.userDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_DATABASE_<DB>_PASSWORD¶
Purpose: The password used to authenticate with the PostgreSQL server. Required unless SSL client certificate authentication is configured (both
SSL_CERTandSSL_KEYare set).Snap key:
landscape.database.<db>.passwordDefault: None
Required: No
service.conf-supplied: Yes
LANDSCAPE_DATABASE_<DB>_SSL¶
Purpose: The SSL mode to use when connecting to PostgreSQL. Valid values are
disable,allow,prefer,require,verify-ca, andverify-full.Snap key:
landscape.database.<db>.sslDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_DATABASE_<DB>_SSL_ROOT_CERT¶
Purpose: Path to the root CA certificate file used to verify the server’s certificate. Required when
SSLis set toverify-caorverify-full.Snap key:
landscape.database.<db>.ssl-root-certDefault: None
Required: No
service.conf-supplied: Yes
LANDSCAPE_DATABASE_<DB>_SSL_CERT¶
Purpose: Path to the client certificate file used for SSL client certificate authentication. Must be set together with
SSL_KEY.Snap key:
landscape.database.<db>.ssl-certDefault: None
Required: No
service.conf-supplied: Yes
LANDSCAPE_DATABASE_<DB>_SSL_KEY¶
Purpose: Path to the private key file for the client certificate. Must be set together with
SSL_CERT.Snap key:
landscape.database.<db>.ssl-keyDefault: None
Required: No
service.conf-supplied: Yes
Broker settings¶
LANDSCAPE_BROKER_HOST¶
Purpose: The hostname or IP address of the AMQP broker (RabbitMQ).
Snap key:
landscape.broker.hostDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_BROKER_PORT¶
Purpose: The port on which the AMQP broker is listening.
Snap key:
landscape.broker.portDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_BROKER_USER¶
Purpose: The username used to authenticate with the AMQP broker.
Snap key:
landscape.broker.userDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_BROKER_PASSWORD¶
Purpose: The password used to authenticate with the AMQP broker. Required unless SSL client certificate authentication is configured (both
SSL_CERTandSSL_KEYare set).Snap key:
landscape.broker.passwordDefault: None
Required: No
service.conf-supplied: Yes
LANDSCAPE_BROKER_VHOST¶
Purpose: The virtual host namespace to use on the AMQP broker.
Snap key:
landscape.broker.vhostDefault: None
Required: Yes
service.conf-supplied: Yes
LANDSCAPE_BROKER_SSL_CA_CERT¶
Purpose: Path to the CA certificate file used to verify the broker’s TLS certificate. When any SSL variable is set, the connection uses the
amqpsscheme.Snap key:
landscape.broker.ssl-ca-certDefault: None
Required: No
service.conf-supplied: Yes
LANDSCAPE_BROKER_SSL_CERT¶
Purpose: Path to the client certificate file used for mTLS authentication with the broker. Must be set together with
SSL_KEY.Snap key:
landscape.broker.ssl-certDefault: None
Required: No
service.conf-supplied: Yes
LANDSCAPE_BROKER_SSL_KEY¶
Purpose: Path to the private key file for the broker client certificate. Must be set together with
SSL_CERT.Snap key:
landscape.broker.ssl-keyDefault: None
Required: No
service.conf-supplied: Yes
Worker settings¶
LANDSCAPE_WORKER_BATCH_SIZE¶
Purpose: The maximum number of outbox entries to read and publish in a single iteration of the worker loop.
Snap key:
landscape.worker.batch-sizeDefault:
50Required: No
service.conf-supplied: No
LANDSCAPE_WORKER_SLEEP¶
Purpose: A fixed delay introduced between every worker loop iteration, regardless of whether entries were found. Accepts Go duration strings (for example
500ms,1s).Snap key:
landscape.worker.sleepDefault:
0sRequired: No
service.conf-supplied: No
LANDSCAPE_WORKER_IDLE_SLEEP¶
Purpose: The duration the worker sleeps between iterations when no outbox entries were found in the previous iteration. Accepts Go duration strings.
Snap key:
landscape.worker.idle-sleepDefault:
1sRequired: No
service.conf-supplied: No
LANDSCAPE_WORKER_QUEUE_SLEEP¶
Purpose: The duration the worker sleeps between iterations when the broker’s publish queue is full. Accepts Go duration strings.
Snap key:
landscape.worker.queue-sleepDefault:
1sRequired: No
service.conf-supplied: No
LANDSCAPE_WORKER_MAX_RETRIES¶
Purpose: The maximum number of times the worker will retry publishing a single outbox entry before marking it as failed.
Snap key:
landscape.worker.max-retriesDefault:
3Required: No
service.conf-supplied: No
Logging settings¶
LANDSCAPE_LOGGING_LEVEL¶
Purpose: The minimum log level for the service. Valid values are
trace,debug,info,warn,error, andfatal.Snap key:
landscape.logging.levelDefault:
infoRequired: No
service.conf-supplied: No
LANDSCAPE_LOGGING_HUMAN_READABLE¶
Purpose: When
true, log output is formatted for human readability. Whenfalse, logs are emitted as structured JSON.Snap key:
landscape.logging.human-readableDefault:
falseRequired: No
service.conf-supplied: No
Service identity settings¶
These settings identify the service instance to telemetry and observability systems. They are optional; if unset, the corresponding fields are omitted from telemetry data.
LANDSCAPE_SERVICE_NAME¶
Purpose: The name reported by this service instance to the telemetry backend.
Snap key:
landscape.service.nameDefault: None
Required: No
service.conf-supplied: No
LANDSCAPE_SERVICE_VERSION¶
Purpose: The version string reported by this service instance to the telemetry backend.
Snap key:
landscape.service.versionDefault: None
Required: No
service.conf-supplied: No
LANDSCAPE_SERVICE_NAMESPACE¶
Purpose: The namespace reported by this service instance to the telemetry backend.
Snap key:
landscape.service.namespaceDefault: None
Required: No
service.conf-supplied: No
LANDSCAPE_SERVICE_ENVIRONMENT¶
Purpose: The environment name (for example
productionorstaging) reported by this service instance to the telemetry backend.Snap key:
landscape.service.environmentDefault: None
Required: No
service.conf-supplied: No
Telemetry settings¶
LANDSCAPE_TELEMETRY_ENDPOINT¶
Purpose: The OTLP endpoint URL to which the service sends telemetry data (traces and metrics). When unset, telemetry is disabled.
Snap key:
landscape.telemetry.endpointDefault: None
Required: No
service.conf-supplied: No
landscape-outbox.cleanup service¶
The cleanup service purges old outbox entries from the database on a periodic schedule. It shares the database and logging configuration with the main outbox service but does not connect to the broker.
Database settings¶
The cleanup service connects to two PostgreSQL databases: main and account. The configuration keys are identical to those described in the outbox service database settings above, using LANDSCAPE_DATABASE_MAIN_* and LANDSCAPE_DATABASE_ACCOUNT_*.
The cleanup service does not use the resource database.
Logging settings¶
The cleanup service uses the same LANDSCAPE_LOGGING_LEVEL and LANDSCAPE_LOGGING_HUMAN_READABLE environment variables described in logging settings above.
Cleanup settings¶
LANDSCAPE_CLEANUP_SENT_RETENTION_DURATION¶
Purpose: How long to retain successfully sent outbox entries before they are eligible for deletion. Accepts Go duration strings.
Snap key:
landscape.cleanup.sent-retention-durationDefault:
24hRequired: No
service.conf-supplied: No
LANDSCAPE_CLEANUP_FAILED_RETENTION_DURATION¶
Purpose: How long to retain failed outbox entries before they are eligible for deletion. Accepts Go duration strings.
Snap key:
landscape.cleanup.failed-retention-durationDefault:
720h(30 days)Required: No
service.conf-supplied: No
LANDSCAPE_CLEANUP_BATCH_SIZE¶
Purpose: The maximum number of entries to delete in a single database operation.
Snap key:
landscape.cleanup.batch-sizeDefault:
50Required: No
service.conf-supplied: No
LANDSCAPE_CLEANUP_BATCH_SLEEP¶
Purpose: The duration the cleanup job sleeps between successive delete batches. Accepts Go duration strings.
Snap key:
landscape.cleanup.batch-sleepDefault:
50msRequired: No
service.conf-supplied: No