The UmbraAudio side of the cross-machine contract: this node registers with the UmbraTrans controller, polls for jobs, claims them under a lease, and writes artifacts back over NFS. * `umbraaudio/cluster/` - configuration, PostgreSQL access, node registration and heartbeat, the job queue, artifact storage and NFS mount management. * `scripts/cluster_worker.py` - the CLI: `worker`, `check-cluster`, `register-node`. * `scripts/backup_system.sh` / `scripts/verify_backup.sh` - whole-system backup and integrity verification. * `.env` - the `UMBRA_CLUSTER__*` settings. `UMBRA_CLUSTER__PG_PASSWORD` is deliberately empty; the password comes from the environment, not from a committed file. `k3s-agent.yaml` is NOT committed: it contains a K3s server join token. It is now gitignored, and the token should be rotated if that file has ever left this machine. ruff clean on the whole package.
34 lines
889 B
Python
34 lines
889 B
Python
"""UmbraTrans cluster integration for UmbraAudio.
|
|
|
|
Provides PostgreSQL connection, compute node registration, job queue,
|
|
artifact protocol, and NFS shared storage access.
|
|
"""
|
|
|
|
from __future__ import annotations
|
|
|
|
from .artifacts import ArtifactStore, read_artifact, write_artifact
|
|
from .config import ClusterConfig, load_cluster_config
|
|
from .database import ClusterDB, get_cluster_db
|
|
from .jobs import JobKind, JobQueue, claim_job, complete_job
|
|
from .nfs import NFSMounts, ensure_nfs_mounts
|
|
from .node import ComputeNode, heartbeat_loop, register_node
|
|
|
|
__all__ = [
|
|
"ClusterConfig",
|
|
"load_cluster_config",
|
|
"ClusterDB",
|
|
"get_cluster_db",
|
|
"ComputeNode",
|
|
"register_node",
|
|
"heartbeat_loop",
|
|
"JobQueue",
|
|
"JobKind",
|
|
"claim_job",
|
|
"complete_job",
|
|
"ArtifactStore",
|
|
"write_artifact",
|
|
"read_artifact",
|
|
"NFSMounts",
|
|
"ensure_nfs_mounts",
|
|
]
|