gitoria

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit641f3b54641f3b54Tracker: Apollo answermre641f3b54/tests/realdata-m034.sh

2.0 KB

  1. #!/bin/bash
  2. # realdata-m034.sh <start|stop> <tree> <copy> <port> — mission 034 (tracker#40, the curated franchise seed), NOT the gate. Starts an
  3. # app tree on a COPY of live `storage/` (<copy>/storage, STATUS "How to repeat") with every background job OFF but the franchise
  4. # seed (TRACKER_COLLECTIONS=1 in the caller's env: the collection seed too). With a `.env` link in <tree> (real TMDB token, never read) the seed imports what is missing; without one it only builds.
  5. # Writes a session for the creator (az5b2 = user 0mujqspn0aqb) → <copy>/sid; log <copy>/server.log, RSS every 10 s <copy>/rss.log;
  6. # stop kills the PID in <copy>/server.pid.
  7. mode=$1; tree=$2; R=$3; port=$4
  8. if [ "$mode" = stop ]; then pid=$(cat $R/server.pid); kill $pid; while kill -0 $pid 2>/dev/null; do sleep 1; done; echo "stopped $pid"; exit 0; fi
  9. mkdir -p $R/sessions
  10. sid=$(head -c 16 /dev/urandom | xxd -p); now=$(date +%s%3N)
  11. echo "{\"created\":$now,\"data\":{\"tag\":\"t\"},\"id\":\"$sid\",\"seen\":$now,\"user\":{\"id\":\"0mujqspn0aqb\"}}" > $R/sessions/$(printf %s "$sid" | sha256sum | cut -d' ' -f1)
  12. echo $sid > $R/sid
  13. cd $tree
  14. env TRACKER_SYNC=0 TRACKER_ART=0 TRACKER_PHOTOS=0 TRACKER_BACKFILL=0 TRACKER_REPAIR=0 TRACKER_KINDS=0 TRACKER_CREDITS=0 TRACKER_COLLECTIONS=${TRACKER_COLLECTIONS:-0} TRACKER_MERGE=0 TRACKER_SHORTIDS=0 \
  15. TRACKER_PORT=$port TRACKER_URL=http://127.0.0.1:$port HL_HOST=127.0.0.1 TRACKER_WATCH=0 \
  16. TRACKER_STORAGE=$R/storage/mpackdb TRACKER_SESSIONS=$R/sessions/ TRACKER_OLD_SHORT_IDS=$tree/data/old-short-ids.json \
  17. setsid ./bin/hybriel project.hl >> $R/server.log 2>&1 < /dev/null &
  18. pid=$!; echo $pid > $R/server.pid
  19. ( t0=$(date +%s); while kill -0 $pid 2>/dev/null; do echo "$(( $(date +%s) - t0 )) $(date +%T) $(awk '/VmRSS/{print $2}' /proc/$pid/status 2>/dev/null)" >> $R/rss.log; sleep 10; done ) > /dev/null 2>&1 < /dev/null &
  20. t0=$(date +%s)
  21. until curl -s -o /dev/null http://127.0.0.1:$port/; do sleep 1; kill -0 $pid 2>/dev/null || { echo "server died"; tail -20 $R/server.log; exit 1; }; done
  22. echo "pid $pid listening after $(( $(date +%s) - t0 )) s"

Branches

Latest commits

  • 641f3b54Tracker: Apollo answermre
  • 8b3cbddaTracker: status, TR7 fix livemre
  • ec30162aTracker: TR7 fix livemre
  • 54cbec80compose: ignore SIGPIPE (TR7 crash loop, exit 141)mre
  • 3e164b63Tracker: status after CL1mre
  • 9d686bb3Tracker: CL1 reviewedmre
  • b8bba562CL1: crash loop report (SIGPIPE confirmed, trap wrapper option)mre
  • 298785f2Tracker: CL1 startedmre
  • 36b22710Tracker: port slot, CL1 briefmre
  • a401190fTracker: GO for the crash loopmre
  • e195d372Tracker: token pathsmre
  • 7f541d11Tracker conductor: CONDUCTOR.md, short STATUS.md, old status + decisions archive to archive/2026-10-31mre
  • 8dd423f7README: login.js stays by caramboleyo's explicit rulemre
  • d8df1493tracker: standby service on port 45018 and a gap-free hand-over in deploy.sh step 4mre
  • 36dd1686ident#31: the selector's sign-in returns to the page the user started on (return attribute = the login callback with next), gate checkmre
  • ff9b838etracker: the Ended status pill uses the same red as layouts (pill danger); gate updatedmre
  • 40d9719eTP2: LOG line and report for the tracker pillsmre
  • ab3f2ba5tracker: status, genres, TMDB/IMDb/TVDB/TVmaze links and list kinds use the theme's pill; dense season list with the season check centred on its title line; gates for bothmre
  • 521061d6tracker header on phones: signed in, the brand fits whole at 360 and 390 px (tighter gaps and side paddings, slightly smaller brand, narrow screens and signed in only); mobile gate checks itmre
  • 18114a53tracker: franchises gate waits for the signed-out selector instead of the removed Log in buttonmre