Files
homelabstack/stacks/romhacks/orchestrator/run.sh
T
ginnoir ba207a0fcd feat(romhacks): add Discord rom-hack ingestion stack (DCE -> JDownloader -> RomM)
Inert by default: empty token keeps the orchestrator idle and DRY_RUN=true
suppresses downloads. Orchestrator exports per-generation forum threads via
DiscordChatExporter, extracts download links + art, stages metadata, and writes
JDownloader crawljobs. Armed here with an alt account token and all 11 romhack
forums, still in DRY_RUN pending first-cycle validation.
2026-06-07 18:53:23 -05:00

16 lines
509 B
Bash

#!/bin/sh
# Harvest loop. Stays idle (no export, no enqueue) until the alt-account token and
# guild id are configured, so deploying the stack unconfigured is harmless.
set -u
POLL_INTERVAL="${POLL_INTERVAL:-21600}"
while true; do
if [ -z "${DISCORD_TOKEN:-}" ] || [ -z "${GUILD_ID:-}" ]; then
echo "[romhacks] DISCORD_TOKEN/GUILD_ID not set — idle. Sleeping ${POLL_INTERVAL}s."
else
python3 /app/orchestrate.py || echo "[romhacks] cycle failed (exit $?)"
fi
sleep "${POLL_INTERVAL}"
done