Skip to main content

DevOps Sentinel Next

Python 3.10+ License: MIT

Terminal-first SRE operations for health checks, incidents, evidence-backed response plans, and postmortems.

DevOps Sentinel works locally without Supabase, an account, or an API server. Team deployments can keep using Supabase compatibility mode. Python remains canonical runtime; FastAPI, MCP, web console, and npm client use shared contracts.

Why Sentinel?

  • Local-first: SQLite persistence and local identity work offline.
  • Fast signal: HTTP health checks with latency, status, SSL, retries, and suggestions.
  • Incident memory: Store health evidence, incident timelines, response plans, and postmortems.
  • Agent-ready: Expose safe operational context to Claude, Cursor, and other MCP hosts.
  • Multi-agent response: Watcher, First Responder, Investigator, and Strategist roles coordinate response.
  • Safe by default: Agents recommend remediation; destructive actions require explicit approval.
  • Scriptable: Consistent CLI commands, JSON output, and CI-friendly API tokens.
  • Self-hostable: Local SQLite by default, optional Supabase compatibility, no telemetry.

Quick start — no Supabase

pip install devops-sentinel-next
sentinel init
sentinel status
sentinel health https://api.example.com/health
sentinel services add production-api https://api.example.com/health
sentinel services list
sentinel services check <service-id>
sentinel incidents list

sentinel init defaults to local mode:

  • Data: .sentinel/sentinel.db in initialized project
  • Identity: local@localhost
  • Login: not required
  • API server: not required for CLI monitoring
  • AI and Slack: optional

Useful local commands:

sentinel whoami
sentinel config
sentinel doctor
sentinel monitor https://api.example.com/health --failure-threshold 3
sentinel postmortem generate <incident-id> --output postmortem.md

Run sentinel init --mode supabase only when using existing Supabase auth and persistence.

Configuration

.env is loaded from the current project directory. Provider keys can also be stored in a user-level file, similar to CLI auth stores:

sentinel config set openrouter_api_key
sentinel config set openai_api_key
sentinel config list
sentinel config remove openrouter_api_key

config set prompts with hidden input and stores values in ~/.sentinel/config.json with restrictive permissions. Existing process variables and project .env values take precedence. sentinel config always masks secrets. Local mode needs no login; sentinel login is only for Supabase compatibility mode.

Local-first example:

SENTINEL_MODE=local
SENTINEL_DATA_DIR=.sentinel
OPENROUTER_API_KEY=
SLACK_WEBHOOK_URL=

Optional compatibility mode:

SENTINEL_MODE=supabase
SUPABASE_URL=https://your-project.supabase.co
SUPABASE_ANON_KEY=your-key

Configuration precedence: process environment, project .env, user config, defaults. Secrets are redacted by sentinel config.

Service commands use the services namespace:

sentinel services add production-api https://api.example.com/health
sentinel services list
sentinel services check <service-id>

HTTP 2xx and 3xx responses count as reachable/healthy. Redirects still appear with their response code.

MCP support is optional:

pip install "devops-sentinel-next[mcp]"
sentinel mcp

Architecture

CLI / FastAPI / MCP / npm client / web console
                         ↓
                 Sentinel application
                         ↓
          Storage adapter + auth adapter
                 ↓                ↓
        SQLite local mode   Supabase compatibility
                         ↓
                  Optional AI / Slack

Storage is behind SentinelDB. SQLite uses the same project, service, health-check, incident, event, and postmortem method contracts as the Supabase adapter. Supabase remains optional so local installs do not need the Supabase Python package.

Monitoring and incident lifecycle

  1. Register a service.
  2. Run a single check or continuous monitor.
  3. Persist health-check evidence.
  4. Open incidents after failure-threshold evaluation.
  5. Record detection, alerting, investigation, and recovery events.
  6. Resolve after recovery-threshold evaluation.
  7. Generate fallback or optional AI-assisted postmortems.
  8. Require human approval before destructive remediation.

Failure and recovery thresholds prevent one transient request from opening or resolving an incident.

Multi-agent workflow

Sentinel uses a staged workflow. Each role has narrow responsibility and evidence context:

Health check
    ↓
Watcher             Detect failure, latency, or anomaly
    ↓
First Responder     Create incident context and notify responders
    ↓
Investigator        Correlate checks, events, deployments, and dependencies
    ↓
Strategist          Produce action plan, runbook suggestion, and postmortem
    ↓
Human approval      Approve any remediation with operational side effects

Agent definitions live in agents.py; orchestration lives in orchestrator.py. The workflow is intentionally non-destructive. Agents can explain and propose; they cannot run arbitrary shell commands or change infrastructure without an approval boundary.

MCP hosts can query read-only operational context:

  • health_check
  • health_check_batch
  • doctor
  • list_incidents
  • get_incident
  • get_incident_events
  • analyze_anomaly
  • generate_postmortem

Start local MCP stdio mode:

devops-sentinel-mcp

Do not expose remote MCP directly to the public internet without authentication, authorization, rate limiting, and audit logging.

Web console

Web console uses same terminal language as CLI:

  • black background
  • IBM Plex Mono typography
  • restrained borders and green health accent
  • keyboard-visible focus states
  • accessible tables and empty states
  • no glassmorphism or decorative gradients in operator surfaces

Run it during development:

cd web
npm install
npm run dev

Operator routes:

  • /operator/services
  • /operator/incidents
  • /operator/incidents/:incidentId

npm client

packages/client calls the HTTP API. It does not duplicate Python monitoring logic.

cd packages/client
npm install
npm run build

Publish target: @devops-sentinel/client.

Development and verification

python -m pip install -e ".[dev]"
pytest -q -o addopts=""
python -m ruff check sentinel tests
cd web
npm run lint
npm run build

MIT License.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

devops_sentinel_next-0.1.2.tar.gz (150.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

devops_sentinel_next-0.1.2-py3-none-any.whl (159.8 kB view details)

Uploaded Python 3

File details

Details for the file devops_sentinel_next-0.1.2.tar.gz.

File metadata

  • Download URL: devops_sentinel_next-0.1.2.tar.gz
  • Upload date:
  • Size: 150.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.5

File hashes

Hashes for devops_sentinel_next-0.1.2.tar.gz
Algorithm Hash digest
SHA256 d3ab0d1d28c6d6204874565e459c16a3474152267490bf1c01196c459c6d234c
MD5 c8e834b111263e566bcfd003399034eb
BLAKE2b-256 4588397236f817eb37d0688972ac9743443e3aae5dae37f093e85e3cc638fb8b

See more details on using hashes here.

File details

Details for the file devops_sentinel_next-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for devops_sentinel_next-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 1b374682ce0f4f1f44ca79a4029177d03a4f104e25e271834e28a7e90c880ad2
MD5 6d6a3f59451b8bdea8734a21d54c4ee8
BLAKE2b-256 451c36afa672f30b2e270bb6af9ec4c0f531efb4a82e408daf845f4cdca4a0ab

See more details on using hashes here.

Release history Release notifications | RSS feed

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

This release

0.1.2 This release

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page