Skip to content

State and Persistence

Steven Koch edited this page Oct 19, 2025 · 12 revisions

Containers can be treated as replaceable units where state is managed and applied during convergence.

Local share bootstrap

/share is initially bootstrapped from the files located in local/share and will be inherited.

Important: For runtime replacement put fixed SSH key files ({id} respectively {id}.pub; id: container‘s mapping to PVE set in config.env) to local/share/.ssh (or copy automatically created keys from /share/.ssh; permissions from within config container will be required) so Proxmox-GitOps will use instead of generating them.

Network share

The network share /share is the shared mount point used for persistence.

  • /share/.ssh: Contains SSH keys that persist a container's identity across recreations. The base role automatically manages keys in this directory.
  • /share/snapshots: The default location for container snapshots, managed by the Utils.snapshot library (/config/libraries/utils.rb).

Host independence

To make the Proxmox host itself disposable, the state can be externalized. The MOUNT variable in config.env allows mapping an external medium (e.g., external hard disk); so config container's shared directory can be externalized providing snapshots/ auto-mounted to the container’s share.

This can be used to decouple the state from the host. Proxmox VE can be replaced; By mounting the external share and rerun the one-click bootstrap, the entire environment — including container states and configurations are restored from persistent snapshot.

Clone this wiki locally