Files
openclaw/scripts/setup-tm4.sh
T
Tabula Myriad a9ae1a6778 feat: Triad development iteration complete
Matrix Protocol:
- docker-compose.matrix.yml: Dendrite homeserver + PostgreSQL + Nginx TLS
- src/channels/plugins/matrix-channel.ts: OpenClaw plugin implementation
- docs/matrix-triad-setup.md: Setup guide with auth scheme (@tm1-4:triad.local)

MCP Server Integration:
- docs/mcp-triad-integration.md: SearXNG, Playwright, GitHub MCP configs
- docs/mcp-curiosity-mapping.md: Gap-to-capability mapping

Node Sync Architecture:
- src/services/node-sync-service.ts: WebSocket peer sync + presence detection
- src/services/node-sync-service.test.ts: Unit tests
- docs/node-sync-architecture.md: Architecture docs

Triad Resilience:
- scripts/triad-corruption-check.mjs: SQLite + log + config + git integrity
- docs/triad-resilience.md: Recovery procedures
- .secure/deployment-logs/README.md: Schema v2
- skills/triad-heartbeat/SKILL.md: Corruption check integration

NPM Publish Workflow:
- scripts/npm-publish.mjs: version, changelog, validate, publish, rollback
- .github/workflows/npm-publish.yml: GitHub Actions with provenance
- docs/npm-publish-guide.md: Complete documentation

All deliverables tested in Docker before production.
2026-03-24 00:44:50 -04:00

60 lines
2.1 KiB
Bash
Executable File

#!/bin/bash
# TM-4 Setup Script — Run manually on tabula-myriad-4 (192.168.31.205)
# Usage: ssh root@192.168.31.205 'bash -s' < setup-tm4.sh
set -e
echo "🦞 === TM-4 Setup for Deployment Testing ==="
echo ""
# Create openclaw user if not exists
if ! id openclaw &>/dev/null; then
useradd -m -s /bin/bash openclaw
echo "openclaw ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers
echo "✅ Created openclaw user"
fi
# Setup workspace
mkdir -p /home/openclaw/.openclaw/workspace
chown -R openclaw:openclaw /home/openclaw/.openclaw
echo "✅ Created workspace directory"
# Clone Heretek-AI/openclaw
su - openclaw -c "git clone https://github.com/Heretek-AI/openclaw.git /home/openclaw/.openclaw/workspace" && \
echo "✅ Cloned Heretek-AI/openclaw" || echo "⚠️ Clone may already exist"
# Install dependencies
su - openclaw -c "cd /home/openclaw/.openclaw/workspace && npm install" && \
echo "✅ Installed npm dependencies" || echo "⚠️ Install may have run already"
# Initialize triad ledger
su - openclaw -c "cd /home/openclaw/.openclaw/workspace && node scripts/init-triad-ledger.js" && \
echo "✅ Initialized triad ledger" || echo "⚠️ Ledger may already exist"
# Setup SSH key for triad access
mkdir -p /home/openclaw/.ssh
chown openclaw:openclaw /home/openclaw/.ssh
# Note: Paste triad_key.pub content here manually
echo ""
echo "⚠️ SSH Key Setup Required:"
echo " 1. Get triad_key.pub from TM-1 (silica-animus):"
echo " cat /home/openclaw/.ssh/triad_key.pub"
echo ""
echo " 2. Add to TM-4 authorized_keys:"
echo " echo '<paste triad_key.pub here>' >> /home/openclaw/.ssh/authorized_keys"
echo " chown openclaw:openclaw /home/openclaw/.ssh/authorized_keys"
echo " chmod 600 /home/openclaw/.ssh/authorized_keys"
echo ""
# Install heretek-openclaw deployer (optional)
echo "🦞 Optional: Install heretek-openclaw deployer"
echo " git clone https://github.com/Heretek-AI/heretek-openclaw.git"
echo " cd heretek-openclaw && ./first-run.sh"
echo ""
echo "✅ TM-4 base setup complete"
echo ""
echo "After SSH key setup, verify from TM-1:"
echo " ssh -i /home/openclaw/.ssh/triad_key root@192.168.31.205 'hostname'"