spb/company-atlas
Public
Python 66.3%
TypeScript 22.7%
JavaScript 8.6%
HTML 1.4%
CSS 0.7%
1#!/bin/bash2# Render deploy/company-atlas.mld.json with the real secrets and push it to the mld gateway (M1M32:~/dispatch/apps/).3# Usage: deploy/render-manifest.sh [--push]4# Secrets (git-ignored): deploy/.admin-token (generated if missing), deploy/.llm-key (llm-api.io key "company-atlas"; optional).5set -euo pipefail6cd "$(dirname "$0")/.."7TOKEN_FILE=deploy/.admin-token8LLM_FILE=deploy/.llm-key9[ -s "$TOKEN_FILE" ] || { openssl rand -hex 24 > "$TOKEN_FILE"; chmod 600 "$TOKEN_FILE"; echo "generated $TOKEN_FILE"; }10TOKEN=$(tr -d '\n' < "$TOKEN_FILE")11LLM_KEY=""12[ -s "$LLM_FILE" ] && LLM_KEY=$(tr -d '\n' < "$LLM_FILE") || echo "warning: $LLM_FILE missing — LLM enrichment disabled in production"13mkdir -p deploy/rendered14sed -e "s/{{ADMIN_TOKEN}}/$TOKEN/g" -e "s#{{LLM_KEY}}#$LLM_KEY#g" deploy/company-atlas.mld.json > deploy/rendered/company-atlas.json15python3 -c "import json; json.load(open('deploy/rendered/company-atlas.json')); print('manifest ok')"16if [ "${1:-}" = "--push" ]; then17 scp -q deploy/rendered/company-atlas.json M1M32:~/dispatch/apps/company-atlas.json18 ssh M1M32 'chmod 600 ~/dispatch/apps/company-atlas.json && echo "pushed to M1M32:~/dispatch/apps/company-atlas.json"'19fi20