- infrastructure/proxmox/: CT provisioning configs - infrastructure/fabric/gitops/: GitOps layer - fleet.yaml: GPU inventory (Dell GTX 1050 vfio-pci passthrough) - firmware/: ESP32 firmware tree (67 files, 6.9MB) - realms/savearth/: Savearth team realm with heteronyms - lab-gateway: ESP client + manager - CI: Forgejo + GitHub Actions workflows Co-authored-by: Álvaro de Campos <campos@portugalfuturista.org> |
||
|---|---|---|
| .. | ||
| fleet.yaml | ||
| gen-ansible.py | ||
| identity.md | ||
| inventory.yml | ||
| pfctl.py | ||
| prometheus.yml | ||
| README.md | ||
PF Fleet Control — Unified Infrastructure Management
Single source of truth for all Portugal Futurista infrastructure: Proxmox CTs/VMs, Hetzner cloud, and physical hosts — all treated equally.
Quick Start
# List all nodes
pfctl ls
# List only running nodes
pfctl ls --running
# List nodes on a specific host
pfctl ls --host gigabyte
# SSH into any node (by VMID or name)
pfctl ssh 223
pfctl ssh pf-edge
# Run a command on one node
pfctl exec 223 "systemctl status pf-gbrain"
# Run a command on EVERY running node
pfctl exec all "uname -r"
# Start/stop/restart any node
pfctl start 208
pfctl stop 223
pfctl restart 217
# Detailed status (with live uptime)
pfctl status 223
# Cloud cost summary
pfctl cost
# Live dashboard (auto-refresh)
pfctl dashboard
# Rescan Proxmox and update inventory
pfctl update-inventory
Files
| File | Purpose |
|---|---|
fleet.yaml |
Master inventory — all nodes, specs, IPs, roles |
pfctl.py |
Unified CLI (pfctl) |
gen-ansible.py |
Generates Ansible inventory from fleet.yaml |
prometheus.yml |
Unified Prometheus scrape config |
inventory.yml |
Generated Ansible inventory (run gen-ansible.py --write) |
Architecture
pfctl (CLI)
├── fleet.yaml (single source of truth)
│
├── Proxmox nodes → SSH tunnel to ASUS → pct exec / qm guest exec
├── Hetzner VMs → direct SSH (public IP)
└── Physical hosts → SSH via tunnel
pfctl auto-detects the node type and routes commands through the right backend.
No knowledge of Proxmox internals or hcloud needed — just pfctl exec 223.
Adding a New Node
- Provision (via OpenTofu or manually)
- Add entry to
fleet.yamlunder the right section (hosts,cloud, ornodes) - Run
pfctl update-inventoryto sync specs from Proxmox API - Run
python3 gen-ansible.py --writeto update Ansible inventory
Ansible Integration
# Generate inventory
python3 infrastructure/fleet/gen-ansible.py --write
# Use with ansible
ansible -i infrastructure/fleet/inventory.yml all -m ping
ansible -i infrastructure/fleet/inventory.yml aurelio -m shell -a "systemctl status gbrain"
ansible -i infrastructure/fleet/inventory.yml cloud_vms -m shell -a "uptime"
Groups: proxmox_hosts, cloud_vms, containers, running, aurelio, media, savearth, monitoring.