smithery/pama-lee

ordo-server-deployment

Ordo server deployment and configuration guide. Includes HTTP/gRPC configuration, environment variables, Nomad deployment, Docker, monitoring metrics, audit logging, multi-tenancy configuration. Use for production deployment, operations management, monitoring and alerting.

Installation

$ npx skills add smithery/pama-lee --skill ordo-server-deployment

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from smithery/pama-lee.

npx skills add smithery/pama-lee

Browse all from smithery/pama-lee

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 6,716 B
  • docs SUMMARY.md 303 B

History

  1. First recorded snapshot · 0 installs

SKILL.md

Ordo Server Deployment and Configuration

Quick Start

# Build
cargo build --release

# Basic startup
./target/release/ordo-server

# Startup with persistence
./target/release/ordo-server --rules-dir ./rules

# Full configuration
./target/release/ordo-server \
    --http-addr 0.0.0.0:8080 \
    --grpc-addr 0.0.0.0:50051 \
    --rules-dir ./rules \
    --audit-dir ./audit \
    --log-level info

Environment Variables

Variable Description Default
ORDOHTTPADDR HTTP address 0.0.0.0:8080
ORDOGRPCADDR gRPC address 0.0.0.0:50051
ORDOUDSPATH Unix Socket path -
ORDODISABLEHTTP Disable HTTP false
ORDODISABLEGRPC Disable gRPC false
ORDOLOGLEVEL Log level info
ORDORULESDIR Rules persistence directory -
ORDOMAXVERSIONS Max version count 10
ORDOAUDITDIR Audit log directory -
ORDOAUDITSAMPLE_RATE Audit sample rate (0-100) 10
ORDODEBUGMODE Debug mode false

Multi-tenancy Configuration

Variable Description Default
ORDOMULTITENANCY_ENABLED Enable multi-tenancy false
ORDODEFAULTTENANT Default tenant ID default
ORDODEFAULTTENANT_QPS Default QPS limit -
ORDODEFAULTTENANT_BURST Default burst limit -
ORDODEFAULTTENANTTIMEOUTMS Execution timeout (ms) 100
ORDOTENANTSDIR Tenant config directory -

Signature Verification Configuration

Variable Description Default
ORDOSIGNATUREENABLED Enable signature verification false
ORDOSIGNATUREREQUIRE Reject unsigned rules false
ORDOSIGNATURETRUSTED_KEYS Trusted public keys (comma-separated) -
ORDOSIGNATURETRUSTEDKEYSFILE Public key file path -
ORDOSIGNATUREALLOWUNSIGNEDLOCAL Allow unsigned local rules true

Docker Deployment

Dockerfile

FROM rust:1.75 as builder
WORKDIR /app
COPY . .
RUN cargo build --release

FROM debian:bookworm-slim
COPY --from=builder /app/target/release/ordo-server /usr/local/bin/
EXPOSE 8080 50051
CMD ["ordo-server"]

Run Container

docker run -d \
    -p 8080:8080 \
    -p 50051:50051 \
    -v $(pwd)/rules:/app/rules \
    -e ORDO_RULES_DIR=/app/rules \
    -e RUST_LOG=info \
    ghcr.io/pama-lee/ordo-server:latest

Nomad Deployment

Production Configuration

job "ordo-server" {
  datacenters = ["dc1"]
  type = "service"
  
  update {
    max_parallel     = 1
    min_healthy_time = "10s"
    healthy_deadline = "3m"
    auto_revert      = true
  }
  
  group "ordo" {
    count = 1
    
    network {
      port "http" { static = 8080 }
      port "grpc" { static = 50051 }
    }
    
    service {
      name     = "ordo-http"
      port     = "http"
      provider = "nomad"
      
      check {
        name     = "http-health"
        type     = "http"
        path     = "/health"
        interval = "10s"
        timeout  = "3s"
      }
    }
    
    task "ordo-server" {
      driver = "docker"
      
      config {
        image = "ghcr.io/pama-lee/ordo-server:latest"
        ports = ["http", "grpc"]
      }
      
      env {
        RUST_LOG = "info"
      }
      
      resources {
        cpu    = 500
        memory = 256
      }
    }
  }
}

Deployment Commands

cd deploy/nomad
nomad job run ordo-server.nomad
nomad job status ordo-server

API Endpoints

HTTP API

Endpoint Method Description
/health GET Health check
/metrics GET Prometheus metrics
/api/v1/rulesets GET List all rules
/api/v1/rulesets/:name GET/PUT/DELETE Manage rules
/api/v1/execute/:name POST Execute rule
/api/v1/rulesets/:name/versions GET Version history
/api/v1/rulesets/:name/rollback POST Rollback version

Execute Rule

curl -X POST http://localhost:8080/api/v1/execute/discount-check \
    -H "Content-Type: application/json" \
    -d '{"input": {"user": {"vip": true}, "order": {"amount": 500}}}'

Monitoring Metrics

Prometheus Metrics

ordo_info{version="0.2.0"} 1
ordo_uptime_seconds 3600
ordo_rules_total 12
ordo_executions_total{ruleset="payment-check",result="success"} 1000
ordo_execution_duration_seconds_bucket{ruleset="payment-check",le="0.001"} 950
ordo_execution_duration_seconds_sum{ruleset="payment-check"} 1.5

Grafana Dashboard Queries

# QPS
rate(ordo_executions_total[5m])

# Average latency
rate(ordo_execution_duration_seconds_sum[5m]) / rate(ordo_executions_total[5m])

# P99 latency
histogram_quantile(0.99, rate(ordo_execution_duration_seconds_bucket[5m]))

# Error rate
rate(ordo_executions_total{result="error"}[5m]) / rate(ordo_executions_total[5m])

Audit Logging

Enable Audit

./ordo-server --audit-dir ./audit --audit-sample-rate 10

Log Format (JSON Lines)

{"timestamp":"2024-01-08T10:00:00.123Z","level":"INFO","event":"server_started","version":"0.2.0"}
{"timestamp":"2024-01-08T10:00:01.456Z","level":"INFO","event":"rule_created","rule_name":"payment"}
{"timestamp":"2024-01-08T10:00:02.789Z","level":"INFO","event":"rule_executed","rule_name":"payment","duration_us":1500}

Dynamic Sample Rate Adjustment

# Get current sample rate
curl http://localhost:8080/api/v1/config/audit-sample-rate

# Update sample rate
curl -X PUT http://localhost:8080/api/v1/config/audit-sample-rate \
    -H "Content-Type: application/json" \
    -d '{"sample_rate": 50}'

CLI Tools

Key Generation

./ordo-keygen --output keys/
# Generates: keys/private.key, keys/public.key

Rule Signing

./ordo-sign --key keys/private.key --input rule.json --output rule.signed.json

Signature Verification

./ordo-verify --key keys/public.key --input rule.signed.json

Key Files

  • crates/ordo-server/src/config.rs - Server configuration
  • crates/ordo-server/src/api.rs - HTTP API
  • crates/ordo-server/src/grpc.rs - gRPC service
  • crates/ordo-server/src/metrics.rs - Prometheus metrics
  • crates/ordo-server/src/audit.rs - Audit logging
  • deploy/nomad/ - Nomad deployment configuration