#!/bin/bash echo "=== AITBC Infrastructure Git Status Summary ===" echo "Date: $(date)" echo "" # Check aitbc server echo "=== AITBC Server ===" echo "Status: $(ssh aitbc echo "reachable" 2>/dev/null || echo "NOT REACHABLE")" if ssh aitbc "cd /opt/aitbc" 2>/dev/null; then echo "Branch: $(ssh aitbc 'cd /opt/aitbc && git branch --show-current')" echo "Status: $(ssh aitbc 'cd /opt/aitbc && git status --porcelain' | wc -l) files pending" echo "Last commit: $(ssh aitbc 'cd /opt/aitbc && git log -1 --oneline')" fi echo "" # Check aitbc1 server echo "=== AITBC1 Server ===" echo "Status: $(ssh aitbc1 echo "reachable" 2>/dev/null || echo "NOT REACHABLE")" if ssh aitbc1 "cd /opt/aitbc" 2>/dev/null; then echo "Branch: $(ssh aitbc1 'cd /opt/aitbc && git branch --show-current')" echo "Status: $(ssh aitbc1 'cd /opt/aitbc && git status --porcelain' | wc -l) files pending" echo "Last commit: $(ssh aitbc1 'cd /opt/aitbc && git log -1 --oneline')" fi echo "" # Check aitbc-cascade (local) echo "=== AITBC-Cascade Server (Local) ===" echo "Status: LOCAL" cd /opt/aitbc echo "Branch: $(git branch --show-current)" echo "Status: $(git status --porcelain | wc -l) files pending" echo "Last commit: $(git log -1 --oneline)" echo "" # Check gitea connectivity echo "=== Gitea Server ===" echo "Status: $(ping -c 1 gitea.bubuit.net >/dev/null 2>&1 && echo "REACHABLE" || echo "NOT REACHABLE")" echo "URL: https://gitea.bubuit.net/oib/AITBC.git" echo "" # Check GitHub connectivity echo "=== GitHub Server ===" echo "Status: $(ping -c 1 github.com >/dev/null 2>&1 && echo "REACHABLE" || echo "NOT REACHABLE")" echo "URL: https://github.com/oib/AITBC.git" echo "" echo "=== Summary ===" echo "- aitbc server: Changes committed, ready to push to gitea when reachable" echo "- aitbc1 server: Not reachable, needs investigation" echo "- aitbc-cascade: Local repository clean" echo "- gitea: Not reachable from current network" echo "- github: Available as backup remote"