Skip to content

Configuration Reference

Every Kessel service is configured through a combination of YAML config files, environment variables, and CLI flags. This page lists all available parameters for each service.

Configuration is loaded from .inventory-api.yaml, searched first in the current working directory, then in the home directory. You can set an explicit path with the --config CLI flag or the INVENTORY_API_CONFIG environment variable. All parameters are also available as CLI flags. Environment variables use an INVENTORY_API_ prefix, with dots and hyphens replaced by underscores.

Parameter Type Default Description
server.id string hostname Server identifier
server.name string kessel-inventory-api Server name
server.public_url string http://localhost:8000 Public URL where the server is reachable
server.read-only boolean false Start in read-only mode, blocking write operations
Parameter Type Default Description
server.http.address string 0.0.0.0:8000 Listen address
server.http.timeout-seconds int 300 Request timeout in seconds
server.http.certfile string — TLS certificate file
server.http.keyfile string — TLS private key file
server.http.client-ca-file string — CA file for client certificate validation
server.http.sni-servername string — SNI server name for client certs
server.http.certopt int 3 Client auth type (0-4, maps to Go’s crypto/tls.ClientAuthType)
Parameter Type Default Description
server.grpc.address string 0.0.0.0:9000 Listen address
server.grpc.timeout-seconds int 300 Request timeout in seconds
server.grpc.certfile string — TLS certificate file
server.grpc.keyfile string — TLS private key file
server.grpc.client-ca-file string — CA file for client certificate validation
server.grpc.sni-servername string — SNI server name for client certs
server.grpc.certopt int 3 Client auth type (0-4)
Parameter Type Default Description
server.pprof.enabled boolean false Enable pprof profiling
server.pprof.port string 5000 pprof server port
server.pprof.addr string 0.0.0.0 pprof bind address
Parameter Type Default Description
storage.database enum sqlite3 Database backend: sqlite3 or postgres
storage.max-serialization-retries int 10 Max retries for serialized transactions
storage.outbox-mode enum table Outbox publishing mode: table (outbox_events table) or wal (pg_logical_emit_message, requires postgres)
Parameter Type Default Description
storage.postgres.host string localhost Database host
storage.postgres.port string 5432 Database port
storage.postgres.dbname string — Database name (defaults to username if unset)
storage.postgres.user string — Username
storage.postgres.password string — Password
storage.postgres.sslmode enum — SSL mode: disable, allow, prefer, require, verify-ca, verify-full
storage.postgres.sslrootcert string — SSL root certificate path (PostgreSQL defaults to ~/.postgresql/root.crt if unset)
Parameter Type Default Description
storage.sqlite3.dsn string inventory.db Database file path or connection string

The Inventory API uses a chain-based authenticator. Each entry in the chain is tried in order until one matches.

Parameter Type Default Description
authn.authenticator.type string — Authenticator type (e.g., first_match)
authn.authenticator.chain[].type enum — Entry type: oidc, guest, allow-unauthenticated, x-rh-identity
authn.authenticator.chain[].enable boolean true Enable this authenticator
authn.authenticator.chain[].transport.http boolean true Apply to HTTP
authn.authenticator.chain[].transport.grpc boolean true Apply to gRPC
authn.authenticator.chain[].config map — Authenticator-specific configuration

For oidc chain entries, the config map accepts:

Key Type Default Description
authn-server-url string — Authorization server URL
client-id string — Client ID
principal-user-domain string — Domain qualifier for Kessel principal IDs
insecure-client boolean false Skip TLS cert validation
skip-client-id-check boolean false Skip clientId claim validation
enforce-aud-check boolean false Enforce audience claim check
skip-issuer-check boolean false Skip issuer validation (testing only)
grpc-endpoints string[] — Specific gRPC endpoints this authenticator applies to (omit for all)
Parameter Type Default Description
authz.impl enum allow-all Authorization backend: allow-all or kessel
authz.kessel.url string — Relations API gRPC endpoint
authz.kessel.insecure-client boolean false Skip TLS cert verification
authz.kessel.enable-oidc-auth boolean true Enable OIDC auth to Relations API
authz.kessel.sa-client-id string — Service account client ID
authz.kessel.sa-client-secret string — Service account secret
authz.kessel.sso-token-endpoint string — SSO token endpoint
Parameter Type Default Description
consumer.enabled boolean true Enable the embedded Kafka consumer
consumer.bootstrap-servers string[] — Kafka broker addresses
consumer.consumer-group-id string inventory-consumer Consumer group name
consumer.topic string outbox.event.kessel.tuples Kafka topic
consumer.commit-modulo int 10 Commit offsets every N messages
consumer.session-timeout string 45000 Session timeout (ms)
consumer.heartbeat-interval string 3000 Heartbeat interval (ms)
consumer.max-poll-interval string 300000 Max poll interval (ms)
consumer.enable-auto-commit string false Auto-commit offsets
consumer.auto-offset-reset string earliest Offset reset policy: earliest or latest
consumer.statistics-interval-ms string 60000 librdkafka stats interval (ms)
consumer.debug string — Comma-separated librdkafka debug contexts
consumer.read-after-write-enabled boolean true Enable read-after-write consistency
consumer.read-after-write-allowlist string[] [] Services requiring read-after-write (empty = all)
Parameter Type Default Description
consumer.auth.enabled boolean true Enable Kafka auth
consumer.auth.security-protocol string — Protocol: PLAINTEXT, SSL, SASL_PLAINTEXT, SASL_SSL
consumer.auth.sasl-mechanism string — Mechanism: PLAIN, SCRAM-SHA-256, SCRAM-SHA-512
consumer.auth.sasl-username string — SASL username
consumer.auth.sasl-password string — SASL password
consumer.auth.ca-cert-location string — Kafka CA certificate path
Parameter Type Default Description
consumer.retry-options.consumer-max-retries int 2 Max retries before killing consumer (-1 for unlimited)
consumer.retry-options.operation-max-retries int 3 Max retries per operation
consumer.retry-options.backoff-factor int 5 Exponential backoff multiplier
consumer.retry-options.max-backoff-seconds int 30 Max backoff cap in seconds
Parameter Type Default Description
consistency.read-after-write-enabled boolean true Enable read-after-write consistency
consistency.read-after-write-allowlist string[] [] Services requiring read-after-write
consistency.default-to-at-least-as-acknowledged boolean true Default consistency for Check operations
consistency.idempotency-check-enabled boolean true Enable transaction ID idempotency checks
Parameter Type Default Description
schema.repository enum in-memory Schema repository type (CLI flag: --schema.schemas)
schema.in-memory.Type enum empty In-memory type: empty, json, or dir
schema.in-memory.Path string — Path to schema data (required for json or dir)

In YAML config, use the redhatRbacSelfSubjectStrategy key. CLI flags use --selfsubjectstrategy.redhat-rbac.* instead.

Parameter (YAML) Type Default Description
selfsubjectstrategy.redhatRbacSelfSubjectStrategy.enabled boolean false Enable Red Hat RBAC self-subject strategy
selfsubjectstrategy.redhatRbacSelfSubjectStrategy.issuerDomain string — Domain for x-rh-identity subjects
selfsubjectstrategy.redhatRbacSelfSubjectStrategy.oidcIssuerDomains[].iss string — OIDC issuer URL (YAML only, not available as CLI flag)
selfsubjectstrategy.redhatRbacSelfSubjectStrategy.oidcIssuerDomains[].domain string — Domain for this issuer (YAML only, not available as CLI flag)
Parameter Type Default Description
metaauthorizer.tuple-crud-allowlist string[] [] Client IDs allowed to access tuple CRUD endpoints (empty = deny all, * for testing)
Parameter Type Default Description
business-metrics.enabled boolean false Enable metrics collection from summary table

These parameters are available via YAML config and environment variables only, not CLI flags.

Parameter Type Default Description
log.level enum info Log level: debug, info, warn, error, fatal
log.livez boolean true Enable /api/kessel/v1/livez endpoint
log.readyz boolean true Enable /api/kessel/v1/readyz endpoint

When deployed with Clowder, database and Kafka settings are injected automatically. The config file only needs to specify what Clowder does not provide. Deployments without Clowder will need to supply the full storage, consumer, and auth configuration explicitly.

authn:
authenticator:
type: first_match
chain:
- type: oidc
enable: true
transport:
http: true
grpc: true
config:
authn-server-url: https://sso.example.com/auth/realms/redhat-external
client-id: "my-client-id"
principal-user-domain: redhat
- type: x-rh-identity
enable: true
transport:
http: true
grpc: false
authz:
impl: kessel
kessel:
url: relations-api:9000
enable-oidc-auth: true
sa-client-id: "my-sa-client-id"
sa-client-secret: "my-sa-client-secret"
sso-token-endpoint: https://sso.example.com/protocol/openid-connect/token
schema:
repository: in-memory
in-memory:
type: json
path: schema_cache.json
consumer:
enabled: true
topic: outbox.event.kessel.tuples
log:
level: "info"