# Rename bart → hf-pdocker-03 Design **Date:** 2026-03-11 **Server:** 192.168.86.167 (currently "bart", becoming "hf-pdocker-03") ## Overview Rename the server "bart" to "hf-pdocker-03" across the entire infrastructure — hostname, repository files, NAS paths, Docker Swarm node, monitoring, and documentation. The IP address 192.168.86.167 does not change. ## Scope ### Server-Level - Change hostname from `bart` to `hf-pdocker-03` via `hostnamectl` - Update `/etc/hosts` on the server itself - Docker Swarm: drain → remove → change hostname → re-join with new name - Swarm global services (Telegraf, Node-exporter) auto-reschedule on new node name ### NAS Path Rename - `/mnt/docker-data/compose/bart/` → `/mnt/docker-data/compose/hf-pdocker-03/` - **Onyx exception:** `compose/hf-pdocker-03/onyx/docker-compose.yml` has hardcoded volume mounts referencing `/mnt/docker-data/compose/bart/onyx`. These must be updated in the compose file AND the Onyx containers redeployed after the NAS rename. - All other running containers are unaffected (they don't reference the compose file path at runtime) ### Repository Files **Directory rename:** - `compose/bart/` → `compose/hf-pdocker-03/` (14 files across 8 subdirectories) - Active services: `media/`, `openvas/`, `watchtower/`, `onyx/` - Stale failover dirs (preserved for reference): `smarthome/`, `matrix/`, `guacamole/`, `ai-agents/` **File inventory (all files containing "bart"):** | File | Type | Action | |------|------|--------| | `CLAUDE.md` | Config | Must update — service distribution, storage, internal services | | `stacks/monitoring/prometheus.yml` | Config | Must update — hostname label, job name `http-bart` → `http-hf-pdocker-03` | | `stacks/monitoring/alerts.yml` | Config | Must update — PromQL `hostname="bart"` matchers. Review: elevated 90% CPU threshold was for Frigate, which is now on hf-pdocker-01, not this node. Consider reverting to standard 80% threshold. | | `stacks/monitoring/matrix-receiver-config.yml` | Config | Must update — "bart" in comment. Note: file appears stale (still references old IPs). Update comment only. | | `stacks/frigate/docker-compose.yml` | Stale Swarm def | Update for consistency — has `node.hostname == bart` placement constraint. This is an unused Swarm stack (Frigate runs as standalone Compose on hf-pdocker-01). | | `compose/bart/onyx/docker-compose.yml` | Active compose | **CRITICAL** — has hardcoded volume mount `/mnt/docker-data/compose/bart/onyx:/mnt/gitea_patch:ro`. Must update path AND redeploy Onyx containers. | | `.claude/agents/gitea-backup.md` | Agent def | Must update | | `.claude/agents/alert-manager.md` | Agent def | Must update | | `.claude/agents/documentation-keeper.md` | Agent def | Must update | | `DEPLOYMENT_SUMMARY.md` | Doc | Must update | | `docs/plans/2026-03-08-hf-pdocker-01-phase2-migration.md` | Historical | Update for consistency | | `docs/plans/2026-03-08-hf-pdocker-01-rebuild.md` | Historical | Update for consistency | | `docs/plans/2026-03-07-frigate-notify-v2-plan.md` | Historical | Update for consistency | | `docs/plans/2026-03-05-farm-manager.md` | Historical | Update for consistency | | `docs/plans/2026-03-05-farm-manager-design.md` | Historical | Update for consistency | **Memory/auto-memory files:** - `MEMORY.md` — ~30 references to "bart" - `memory/migration-details.md` — bart references ### Documentation - Wiki pages — infrastructure overview, service access, changelog ## Order of Operations 1. **Repo file updates** — rename `compose/bart/` directory, update all file contents (including Onyx compose volume path). No service impact yet. 2. **SCP updated Onyx compose file** to NAS at the current path (`/mnt/docker-data/compose/bart/onyx/docker-compose.yml`) with the NEW volume path (`/mnt/docker-data/compose/hf-pdocker-03/onyx`). This prepares for the rename. 3. **NAS path rename** — `mv /mnt/docker-data/compose/bart /mnt/docker-data/compose/hf-pdocker-03` (via SSH). Atomic on NFS. 4. **Redeploy Onyx** — `cd /mnt/docker-data/compose/hf-pdocker-03/onyx && docker compose up -d` to pick up the new volume mount path. 5. **Server hostname change** — `sudo hostnamectl set-hostname hf-pdocker-03` + update `/etc/hosts` on 192.168.86.167. 6. **Docker Swarm re-join** — on hf-pdocker-01: drain old bart node, remove it. On 192.168.86.167: leave swarm, re-join with new hostname. Global services auto-schedule. ~30s gap. 7. **Prometheus + alerts** — SCP updated prometheus.yml and alerts.yml, hot-reload. 8. **Update /etc/hosts on other nodes** — if hf-pdocker-01 or hf-pdocker-02 have "bart" in /etc/hosts, update to hf-pdocker-03. 9. **MEMORY.md + Wiki** — update all documentation. 10. **Commit + push to Gitea**. ## Risk Assessment - **Low risk:** Running Compose services (Jellyfin, Sonarr, Radarr, etc.) are unaffected — containers keep running. - **Onyx restart required:** Onyx containers need redeployment after NAS rename to pick up new volume mount path. Brief downtime for Onyx (~30s). - **Low risk:** Swarm global services have ~30s gap during node re-join. - **No IP changes:** All service-to-service communication uses IPs, not hostnames. Nothing breaks at the network level. - **NAS path rename is atomic:** `mv` on NFS is atomic for same-filesystem renames. ## Verification After completion: - `hostname` on 192.168.86.167 returns `hf-pdocker-03` - `docker node ls` on hf-pdocker-01 shows `hf-pdocker-03` instead of `bart` - All containers on 192.168.86.167 still running (`docker ps`) - Onyx containers running with new volume mount path - Prometheus targets for hf-pdocker-03 are UP - `grep -r bart` in repo returns zero matches (excluding git history)