- Integrate ActionMonitor into ChatGPT GitOps API for failure tracking - Add ErrorClassifier with permission, git, runtime, system, secret violation error types - Add FailureRouter to route errors to correct recovery agents (openclaw/hermes/windows_codex_app) - Add RecoveryController orchestrating full pipeline: capture→classify→route→plan→execute→validate→record - Update error_classifier to include ClientResponseError, rate limit, and secret_violation patterns - All 8 integration tests passing (ActionMonitor, ErrorClassifier, FailureRouter, RecoveryController, API 500 scenario) - Push baseline to V1R2C2 with tag v1r2c2-baseline
47 lines
1.5 KiB
Bash
47 lines
1.5 KiB
Bash
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
echo "[AIOS] Installing Autonomous GitOps System..."
|
|
|
|
WORKDIR=/data/aios-gitops/workspace
|
|
ETC=/etc/aios
|
|
RUNTIME=/data/aios-gitops/runtime
|
|
SERVICE_USER=aios
|
|
|
|
if ! id "$SERVICE_USER" >/dev/null 2>&1; then
|
|
echo "[AIOS] Creating system user: $SERVICE_USER"
|
|
useradd --system --home /data/aios-gitops --shell /usr/sbin/nologin "$SERVICE_USER"
|
|
fi
|
|
|
|
mkdir -p "$ETC"
|
|
cp deploy/systemd/aios-autonomous-daemon.env.template "$ETC/aios-autonomous-daemon.env"
|
|
|
|
mkdir -p \
|
|
"$RUNTIME/events" \
|
|
"$RUNTIME/audit" \
|
|
"$RUNTIME/requests" \
|
|
"$RUNTIME/reports/codex" \
|
|
"$RUNTIME/approvals/preapproved" \
|
|
"$RUNTIME/integrations/v1r1-personal-wechat/outbox" \
|
|
"$RUNTIME/integrations/v1r1-personal-wechat/inbox" \
|
|
"$RUNTIME/integrations/v1r1-personal-wechat/status"
|
|
|
|
chown -R "$SERVICE_USER:$SERVICE_USER" /data/aios-gitops/runtime || true
|
|
chown -R "$SERVICE_USER:$SERVICE_USER" "$WORKDIR" || true
|
|
|
|
cp deploy/systemd/aios-autonomous-daemon.service /etc/systemd/system/
|
|
cp deploy/systemd/aios-v1r1-wechat-worker.service /etc/systemd/system/
|
|
|
|
systemctl daemon-reload
|
|
systemctl enable aios-autonomous-daemon.service || true
|
|
systemctl enable aios-v1r1-wechat-worker.service || true
|
|
|
|
systemctl restart aios-autonomous-daemon.service || true
|
|
systemctl restart aios-v1r1-wechat-worker.service || true
|
|
|
|
sleep 2
|
|
systemctl status aios-autonomous-daemon.service --no-pager || true
|
|
systemctl status aios-v1r1-wechat-worker.service --no-pager || true
|
|
|
|
echo "[AIOS] Installation complete"
|