#!/bin/bash # read_boxes.sh — one line per box, read-only: the controller's image and status, Traefik's image. for x in "tester-1 root@192.168.0.154" "demo-hp hp" "demo-felhom felhom-pve"; do set -- $x o=$(ssh -o BatchMode=yes -o ConnectTimeout=10 $2 "pct exec 9201 -- docker ps --format '{{.Names}}|{{.Image}}|{{.Status}}'" 2>&1 | grep -E '^(felhom-controller|traefik)\|') echo "$1: $(echo "$o" | sed 's#gitea.dooplex.hu/admin/felhom-controller:##' | cut -d'|' -f2,3 | tr '\n' ' ')" done