diff --git a/README.md b/README.md index bf0d275..43d6ac4 100644 --- a/README.md +++ b/README.md @@ -46,6 +46,7 @@ Row 0 holds the group buttons. Each one shows the first problem in its group, pl |---|---| | APPS: PROPRES OFFLINE / NOT RUNNING | restarts ProPresenter on its Mac (the newest version installed) | | APPS: ABLETON / TRANSLATE NOT RUNNING | starts Ableton on the Tracks Mac / Church Translate on NA Translation | + | APPS: BIBLE APP DOWN | restarts the Bible app on the Sanctuary TV PC (SSH + its "Start BibleApp" task from `remote-access/windows-setup.ps1`) | | DANTE: PROP MAC / TRACKS / TRANSL / INGEST GONE | starts Dante Virtual Soundcard's engine on that Mac (`remote-access/mac-dvs-helper.sh`) | | DANTE: any device powered by its switch port (today the four Studio B boxes) | power-cycles the port it is on **now**, found by its MAC on the Netgear Dante switches | | DANTE: any other device GONE | restarts Companion's Dante module (hardware: if still gone, it is off or unplugged) | diff --git a/config.json b/config.json index 21680f5..13f4ecd 100644 --- a/config.json +++ b/config.json @@ -31,7 +31,8 @@ "hosts": { "prop": { "ssh": "napropresenter@10.1.14.225" }, "tracks": { "ssh": "waterschurchmedia@10.1.3.227" }, - "translation": { "ssh": "studio@10.1.7.39" } + "translation": { "ssh": "studio@10.1.7.39" }, + "bibletv": { "ssh": "media@10.6.7.13" } }, "fixes": { @@ -49,6 +50,8 @@ "run": "launchctl kickstart -k gui/$(id -u)/org.waterschurch.resi-propresenter || launchctl bootstrap gui/$(id -u) ~/Library/LaunchAgents/org.waterschurch.resi-propresenter.plist" }, "captions": { "kind": "local", "short": "CAPTIONS", "label": "restart lobby captions", "run": "launchctl kickstart -k gui/$(id -u)/org.waterschurch.lobby-captions || launchctl bootstrap gui/$(id -u) ~/Library/LaunchAgents/org.waterschurch.lobby-captions.plist" }, + "bibleapp": { "host": "bibletv", "short": "BIBLE APP", "label": "restart the Bible app on the Sanctuary TV PC (Windows: cmd.exe)", + "run": "taskkill /F /T /IM \"Bible App.exe\" >nul 2>&1 & ping -n 3 127.0.0.1 >nul & schtasks /Run /TN \"\\StatusPanel\\Start BibleApp\"" }, "proddash": { "kind": "local", "short": "PRODDASH", "label": "start ProdDash", "run": "open /Applications/ProdDash.app" }, "hyperdeck": { "kind": "hyperdeck", "short": "HYPERDECK", "label": "reconnect Companion to the HyperDeck, or reboot the deck only if it is hung" } }, @@ -99,7 +102,7 @@ { "type": "remote", "host": "translation", "cmd": "pgrep -xq 'Church Translate'", "msg": "TRANSLATE NOT RUNNING", "fix": "translate" }, { "type": "ping", "host": "10.1.3.227", "name": "TRACKS MAC" }, { "type": "artnet", "source": "10.1.10.206", "max_silence_seconds": 5, "msg": "VISTA SILENT" }, - { "type": "http", "url": "http://10.6.7.13:8080/", "msg": "BIBLE APP DOWN", "interval_seconds": 5 }, + { "type": "http", "url": "http://10.6.7.13:8080/", "msg": "BIBLE APP DOWN", "interval_seconds": 5, "fix": "bibleapp" }, { "type": "conn", "conn": "BibleTV", "tag": "BIBLE OSC" } ] }, diff --git a/tests/test_status_panel.py b/tests/test_status_panel.py index a64a1d2..740c1fc 100644 --- a/tests/test_status_panel.py +++ b/tests/test_status_panel.py @@ -485,6 +485,13 @@ class TestFixes(unittest.TestCase): self.snap.remote["translation\0pgrep -xq 'Church Translate'"] = False self.assertEqual(self.plan("apps"), [("fix", "ableton"), ("fix", "translate")]) + def test_bible_app_is_restarted_on_the_windows_pc(self): + self.snap.http["http://10.6.7.13:8080/"] = False + self.assertEqual(self.plan("apps"), [("fix", "bibleapp")]) + fix = CONFIG["fixes"]["bibleapp"] + self.assertEqual(CONFIG["hosts"][fix["host"]]["ssh"], "media@10.6.7.13") + self.assertIn('schtasks /Run /TN "\\StatusPanel\\Start BibleApp"', fix["run"]) # cmd.exe, not sh + def test_unreachable_mac_is_not_a_verdict(self): self.snap.remote["tracks\0pgrep -xq Live"] = None self.assertEqual(self.plan("apps"), [])