openclaw-aegis 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Canary Builds
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,113 @@
1
+ # OpenClaw Aegis
2
+
3
+ **Self-healing sidecar for the OpenClaw Gateway.**
4
+
5
+ Aegis monitors your OpenClaw gateway, detects failures in seconds, fixes them automatically, and alerts you through out-of-band channels that don't depend on the gateway being up.
6
+
7
+ [![CI](https://github.com/Canary-Builds/openclaw-aegis/actions/workflows/ci.yml/badge.svg)](https://github.com/Canary-Builds/openclaw-aegis/actions/workflows/ci.yml)
8
+ [![Node.js](https://img.shields.io/badge/node-%3E%3D18-brightgreen)](https://nodejs.org)
9
+ [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
10
+
11
+ ---
12
+
13
+ ## Why Aegis?
14
+
15
+ When your OpenClaw gateway crashes, **everything goes dark** — Telegram, WhatsApp, all channels. If the crash was caused by a bad config, restarting doesn't help. The `.bak` files may contain the same poison. You only find out when you notice messages aren't arriving.
16
+
17
+ Aegis prevents this:
18
+
19
+ 1. **Detects** failures via 10 health probes (process, port, config, memory, CPU, disk, logs, network, WebSocket, HTTP)
20
+ 2. **Diagnoses** the root cause using 6 failure pattern matchers
21
+ 3. **Fixes** automatically — restores known-good config, clears stale PIDs, runs safe `doctor --fix`
22
+ 4. **Alerts** you through channels that bypass the gateway entirely (ntfy, Telegram, WhatsApp, Slack, Discord, Email, Pushover, webhook)
23
+
24
+ **Total downtime: ~15 seconds instead of hours.**
25
+
26
+ ---
27
+
28
+ ## Quick Start
29
+
30
+ ```bash
31
+ # Install
32
+ npm install -g openclaw-aegis
33
+
34
+ # Configure (auto-detects your gateway)
35
+ aegis init --auto
36
+
37
+ # Verify
38
+ aegis check
39
+ ```
40
+
41
+ Output:
42
+ ```
43
+ Health: HEALTHY (score: 10)
44
+ Probes: 10 passed, 0 failed
45
+ ```
46
+
47
+ ---
48
+
49
+ ## Commands
50
+
51
+ | Command | Description |
52
+ |---------|-------------|
53
+ | `aegis init` | Interactive setup wizard |
54
+ | `aegis init --auto` | Auto-detect everything, zero prompts |
55
+ | `aegis check` | Run all 10 health probes once |
56
+ | `aegis check --json` | JSON output for scripting |
57
+ | `aegis status` | Health dashboard with per-probe details |
58
+ | `aegis test-alert` | Send a test notification to all configured channels |
59
+
60
+ ---
61
+
62
+ ## Documentation
63
+
64
+ | Document | Description |
65
+ |----------|-------------|
66
+ | [Getting Started](docs/getting-started.md) | Installation, first setup, verification |
67
+ | [Architecture](docs/architecture.md) | System design, probe pipeline, recovery tiers |
68
+ | [Configuration](docs/configuration.md) | Full TOML reference with every option |
69
+ | [Alerts](docs/alerts.md) | Setting up ntfy, Telegram, WhatsApp, webhooks |
70
+ | [CLI Reference](docs/cli-reference.md) | Every command with examples and options |
71
+ | [Contributing](docs/contributing.md) | Development setup, testing, PR process |
72
+
73
+ ---
74
+
75
+ ## How It Works
76
+
77
+ ```
78
+ OpenClaw Gateway Aegis Sidecar
79
+ ┌─────────────────────┐ ┌──────────────────────────────┐
80
+ │ │ │ Health Monitor (10 probes) │
81
+ │ ~/.openclaw/ │◄────────►│ Config Guardian │
82
+ │ openclaw.json │ │ Dead Man's Switch │
83
+ │ logs/ │ │ Recovery Orchestrator │
84
+ │ │ │ L1: Restart │
85
+ │ systemd service │◄─────────│ L2: Targeted Repair │
86
+ │ │ │ L4: Human Alert │
87
+ └─────────────────────┘ │ Alert Dispatcher │
88
+ │ (ntfy/TG/WA/Slack/Webhook) │
89
+ └──────────────────────────────┘
90
+
91
+ Out-of-band
92
+ (never through
93
+ the gateway)
94
+
95
+
96
+ Your phone
97
+ ```
98
+
99
+ ---
100
+
101
+ ## Requirements
102
+
103
+ - Node.js >= 18
104
+ - OpenClaw Gateway (any version with `openclaw gateway health` support)
105
+ - Linux (systemd) or macOS (launchd)
106
+
107
+ ---
108
+
109
+ ## License
110
+
111
+ MIT — see [LICENSE](LICENSE).
112
+
113
+ Built by [Canary Builds](https://github.com/Canary-Builds).
@@ -0,0 +1,2 @@
1
+
2
+ export { }