Skip to Content
Self HostingКонфігурація

Конфігурація

Public self-hosted configuration , checked-in cto-gui/docker-compose.self-hosted.yml plus settings read by cto-gui-libvirt-backend. This page documents that evaluation surface. It does not invent generic Enterprise environment contract.

Compose contract

SettingChecked-in valuePurpose
SELF_HOSTEDtrueSelect local-console mode and disable cloud-dependent routes
KVM_URIqemu:///systemConnect to the host system libvirt daemon
TEST_STORAGE_DIR/app/data/testsRetain test state, locks, and cleanup journals in cto-data
SOURCE_ISO_DIRHost source-ISO pathResolve read-only source artifacts at the same absolute path visible to host libvirt
SOURCE_GOLDEN_IMAGE_DIRHost promoted-image pathResolve immutable installed QCOW2 inputs at the same absolute path visible to host libvirt
TRUST_PROXY_HEADERStrue in the Compose filePermit proxy-derived client information subject to the backend’s trusted-proxy rules

Backend also defaults ISO uploads to /var/lib/libvirt/images and limits uploads to 10 GB unless backend setting deliberately changed.

Host path overrides

Two shell environment variables affect Compose bind mounts:

export SOURCE_ISO_HOST_DIR=/srv/openfactory/source-isos export SOURCE_GOLDEN_IMAGE_HOST_DIR=/srv/openfactory/golden-images docker compose -f docker-compose.self-hosted.yml up --build -d

Create and permission those directories first. Container path kept identical to host path because host libvirt, not container, opens image files for QEMU. Path that exists only inside container will fail at guest launch time.

Persistent and non-persistent data

LocationOwnership and lifecycle
/var/lib/libvirt/imagesHost-managed uploaded ISOs, guest disks, and overlays
Source ISO directoryOperator-managed, mounted read-only
Golden-image directoryOperator-promoted immutable inputs, mounted read-only
cto-data named volumeBackend state including test records and cleanup journals
Container filesystem outside mountsDisposable; do not rely on it for recovery

Back up or snapshot only after identifying which resources must be retained. Compose file does not schedule backups.

Exposure and proxy settings

Frontend maps host port 80. TRUST_PROXY_HEADERS does not provide TLS or authentication; it only changes how backend accepts forwarded connection metadata from explicitly trusted proxy ranges. If you add reverse proxy, configure network path and trusted proxies narrowly and verify spoofed forwarding headers rejected from untrusted peers.

Do not place evaluation console directly on public internet. Production identity, TLS, secrets, and authorization design , separate deployment decision.

Validate every change

After changing paths or settings:

  1. recreate affected container;
  2. verify self_hosted: true through mode endpoint;
  3. upload and launch disposable ISO;
  4. stop and delete guest;
  5. restart stack and confirm cleanup state and inventory survive.