Configuration

Configuration #

The service is configured by environment variables only. The container has no configuration file. Values below are illustrative; a site’s own come from its automation.

Core #

Two variables are required, and the service refuses to start without them.

VariableRequiredMeaning
DEEVNET_API_TOKENyesthe operator bearer token for /v1
DATABASE_URLyesPostgreSQL connection string. The schema is migrated on start
DEEVNET_AGENT_TOKENnothe exit node’s egress agent. It reads GET /v1/fabric/egress and nothing else
DEEVNET_API_LISTENnolisten address, default :8080
DEEVNET_API_TLS_CERT, DEEVNET_API_TLS_KEYnoserve TLS, 1.2 at the least. Set both or neither

With only these set, the service runs and every tenant route answers 501.

Site #

Tenants are served when DEEVNET_SITE is set. Every variable in this table is then required, and the service refuses to start if any is empty.

VariableExampleMeaning
DEEVNET_SITEsitesite label in zone names
DEEVNET_SITE_OCTET20second octet of the site’s address block
DEEVNET_ROOT_DOMAINexample.netthe domain every site’s zones sit under
DEEVNET_VRF_VNI_BASE, DEEVNET_VNET_VNI_BASE10000, 20000bases a tenant’s VXLAN ids derive from
DEEVNET_FABRIC_CONTROLLER, DEEVNET_FABRIC_NODEevpn1, hyp002the attachment every tenant gets
DEEVNET_DNS_UPDATE_SERVERtdns.site.example.netwhere tenants send RFC 2136 updates
DEEVNET_DNS_APEX_NSns1.site.example.netapex NS and SOA primary of tenant zones
DEEVNET_DNS_UPDATE_FROM10.20.50.0/24networks that may attempt an update, comma-separated
DEEVNET_STATE_ENDPOINT, DEEVNET_STATE_BUCKEThttps://tfstate.site.example.net:9000, tf-statethe state store tenants are offered
DEEVNET_RESOLVER_FORWARD_TOthe address the site resolver forwards tenant zones to
DEEVNET_WORKLOAD_RESOLVERthe resolver a workload is given
POWERDNS_API_URLthe tenant DNS server’s HTTP API
OPNSENSE_API_URLthe core router’s API
MINIO_ADMIN_ENDPOINTthe state store’s admin API
PROXMOX_API_URLthe tenant hypervisor’s API
DEEVNET_TENANT_VMID_BASE2000first VMID of the tenant band
DEEVNET_MAC_NAMESPACE02:de:20prefix of the MAC a workload derives from its VMID
DEEVNET_TEMPLATE_PREFIXfedora-server-the newest template matching it is cloned
DEEVNET_TENANT_STORAGE, DEEVNET_TENANT_DISKlocal-lvm, scsi0where a workload lands, and the disk grown
DEEVNET_TENANT_CIUSERthe account a workload’s keys go to, reported as login_user

Secret store #

Backend credentials come from OpenBao when OPENBAO_ADDR is set ( ADR-0016). They are the fields of one KV secret, and the same store seals stored tenant secrets and issues enrollment tokens.

VariableDefaultMeaning
OPENBAO_ADDRturns OpenBao on; the next two rows are then required
OPENBAO_CACERTthe certificate the listener is verified against
OPENBAO_ROLE_ID, OPENBAO_SECRET_IDthe service’s AppRole
OPENBAO_KV_MOUNT, OPENBAO_KV_PATHdeevnet-api, backendswhere the credentials are
OPENBAO_TRANSIT_KEYtenant-secretsthe key that seals stored secrets
DEEVNET_ENROLLMENT_TTL72hhow long an enrollment token lives

The fields the secret holds:

FieldFor
powerdns_api_keythe tenant DNS server
opnsense_api_key, opnsense_api_secretthe core router
minio_admin_access_key, minio_admin_secret_keythe state store
proxmox_token_id, proxmox_token_secretthe tenant hypervisor
token_hmac_keythe MAC key of tenant tokens: base64, at least 32 bytes
omada_client_id, omada_client_secretthe wireless controller; needed only with Wi-Fi keys
broker_writer_keythe broker account writer; needed only with broker accounts
log_writer_keythe log store’s user writer; needed only with the log store
grafana_admin_passwordthe dashboard server; needed only with dashboards

Without OpenBao, the same names are read from the environment in upper case. That is for tests and local runs: there is then no enrollment and no encryption at rest.

Backend TLS #

Each backend is verified unless told otherwise.

VariableDefaultMeaning
OPNSENSE_INSECURE_TLS, PROXMOX_INSECURE_TLSfalsetrue only for a device still serving a self-signed certificate
MINIO_ADMIN_TLSfalsetrue when the state store serves TLS
MINIO_ADMIN_CACERTthe CA the state store is verified against; required with MINIO_ADMIN_TLS
OMADA_INSECURE_TLSfalsetrue only for a wireless controller still serving a self-signed certificate

Optional capabilities #

Each of these capabilities is turned on by one variable, and a site may leave any of them off. An unset capability is not a degraded state: its routes refuse with a reason, and a site with no wireless controller or no broker is a legitimate site.

Wi-Fi keys #

VariableMeaning
OMADA_API_URLthe wireless controller’s API; turns Wi-Fi keys on
DEEVNET_IOT_TRUST_CLASSESthe trust classes served, as comma-separated name=ssid:vlan, for example iot=SITE-IOT:30
DEEVNET_ADMISSION_WIFI_CLASSthe trust class an admission’s Wi-Fi key is issued in; unset, admissions carry none

Fixed device addresses #

VariableDefaultMeaning
DEEVNET_IOT_ADDRESS_RANGESthe part of each trust class’s network tenants are given, as comma-separated name=subnet:first-last, for example iot=10.20.30.0/24:10.20.30.25-10.20.30.200. Each name must be a served trust class
DEEVNET_IOT_ADDRESSES_PER_TENANT16one tenant’s share of a range

They need no credential of their own: the reservations go to the router the resolver forwards already go to.

Broker accounts #

VariableDefaultMeaning
DEEVNET_BROKER_WRITER_ADDRthe messaging host’s writer, reached over SSH; turns broker accounts on
DEEVNET_BROKER_WRITER_USERthe account the writer runs as
DEEVNET_BROKER_HOST_KEYthe host’s public key, pinned
DEEVNET_BROKER_CONNECT_TIMEOUT, DEEVNET_BROKER_SESSION_TIMEOUT10s, 30sreaching the host, and the whole exchange once connected

Log store #

VariableMeaning
DEEVNET_LOG_WRITER_ADDRthe log store’s user writer, reached over SSH; turns log tokens on
DEEVNET_LOG_WRITER_USER, DEEVNET_LOG_HOST_KEYthe account the writer runs as, and the host’s pinned public key
DEEVNET_LOG_CONNECT_TIMEOUT, DEEVNET_LOG_SESSION_TIMEOUTas for the broker’s
DEEVNET_LOG_ENDPOINTwhat a tenant is told to send logs to: the store’s HTTPS address, which is not where the writer lives

Dashboards #

VariableDefaultMeaning
DEEVNET_GRAFANA_URLthe dashboard server, both where the API reaches it and what a tenant is told; turns dashboards on
DEEVNET_GRAFANA_CACERTthe CA the server is verified against
DEEVNET_GRAFANA_ADMIN_USERadminthe server admin the API acts as

Dashboards need the log store: DEEVNET_LOG_ENDPOINT and DEEVNET_LOG_WRITER_ADDR are required with them, because a tenant’s data sources carry its log read token.

Service certificates #

VariableDefaultMeaning
OPENBAO_TENANT_SERVICE_MOUNTthe Tenant Service CA’s PKI mount in OpenBao, for example pki-tenant-service; turns certificates on. It needs OPENBAO_ADDR: the CA is in OpenBao, and nowhere else
OPENBAO_TENANT_SERVICE_ROLEtenant-servicethe one role on that mount the service signs on

They need no credential of their own. The service’s AppRole policy must allow update on <mount>/sign/<role> and nothing else on the mount.

Page last modified: October 11, 2026