Research-Stack/5-Applications/scripts/topology_worker.sh
Brandon Schneider 9b1721eea6 integrate infrastructure config, axiom cleanup, and documentation updates
- cupfox-config.nix: add Open WebUI container with chat.researchstack.info proxy,
  gather-metrics service/timer, rclone, and tmpfiles for persistent storage
- Lean semantics: reduce axiom count from 109 to 18 across 10 files;
  FixedPoint now 0 axioms, 0 sorries with 12 theorems
- Documentation: update AGENTS.md with current axiom/sorry counts and
  FixedPoint status; refine bind signature
- Add topology scripts, CGA/FAMM/GeneticOptimizer/MMRFAMM Lean modules,
  devcontainer config, MEMORY.md, and Modelfile
2026-05-17 12:03:19 -05:00

37 lines
1.6 KiB
Bash

#!/bin/bash
# topology_worker.sh — Connect this node as a worker to the cooperative topology
#
# Usage: ssh allaun@<node-ip> 'bash -s' < topology_worker.sh
# Or run directly on the worker node.
set -euo pipefail
HEAD_IP="100.88.57.96"
HEAD_PORT=6379
echo "╔═══════════════════════════════════════════════════════════╗"
echo "║ Cooperative Compute Topology — Worker Join ║"
echo "╠═══════════════════════════════════════════════════════════╣"
echo "║ Head Node : ${HEAD_IP}:${HEAD_PORT}"
echo "║ This Node : $(hostname)"
echo "╚═══════════════════════════════════════════════════════════╝"
# Check if ray is installed
if ! command -v ray &>/dev/null; then
echo "[!] Ray not found. Installing..."
pip install --user 'ray[default]'
fi
# Check if already connected
if ray status --address="${HEAD_IP}:${HEAD_PORT}" &>/dev/null 2>&1; then
echo "[✓] Already connected to topology head."
ray status --address="${HEAD_IP}:${HEAD_PORT}"
exit 0
fi
# Stop any existing ray processes
ray stop --force 2>/dev/null || true
# Start as worker
echo "[*] Connecting to head node at ${HEAD_IP}:${HEAD_PORT}..."
ray start --address="${HEAD_IP}:${HEAD_PORT}" --block