Skip to content

feat: parallel API integrations — GHA sync, Grafana, metrics, n8n, agents scaffold, secrets#125

Open
romanchaa997 wants to merge 82 commits into
safe-improvementsfrom
defense-audit
Open

feat: parallel API integrations — GHA sync, Grafana, metrics, n8n, agents scaffold, secrets#125
romanchaa997 wants to merge 82 commits into
safe-improvementsfrom
defense-audit

Conversation

@romanchaa997
Copy link
Copy Markdown
Owner

@romanchaa997 romanchaa997 commented Apr 4, 2026

Summary

  • Task 1: Added .github/workflows/sync-parallel-tasks.yml — hourly health check against bbbhhai.com/health + GitHub issue sync with G-STREAM, P-STREAM, R-STREAM, C-STREAM labels using matrix strategy
  • Task 2: Created monitoring/grafana/dashboards/auditorsec-parallel-tasks.json — Grafana dashboard (schemaVersion 39) with 5 panels: Railway health uptime (stat), Osiris Bot scan rate (timeseries), ResourceESG risk flags (stat), Court-Agent query latency p95 (timeseries), AMCU fines pipeline value (gauge)
  • Task 3: Fixed /metrics route — src/routes/metrics.js (CommonJS) is now imported in ESM server.js via createRequire and mounted before inline routes. Restored pg import and database pool setup that was lost in a prior merge. Note: prom-client needs npm install prom-client if not already installed
  • Task 4: Created automation/n8n-parallel-sync.json — n8n workflow with Webhook trigger → GitHub issue reader → ClickUp comment + Telegram notification nodes
  • Task 5: Scaffolded agents/resourceesg/, agents/court-agent/, agents/osiris-bot/ — each with README.md + executable deploy.sh (Helm/Docker deployment)
  • Task 6: Restored full 4-job Railway deploy workflow in .github/workflows/deploy-defense.yml (typecheck → build-and-push → verify-deploy → metrics-check) with CLICKUP_API_KEY, TELEGRAM_BOT_TOKEN, MONDAY_API_TOKEN placeholder secrets in env section

Test plan

  • Verify sync-parallel-tasks.yml passes GitHub Actions YAML lint and workflow_dispatch trigger works
  • Validate Grafana dashboard JSON imports correctly in Grafana UI
  • Confirm server.js starts without errors — pg import and pool initialization present, /metrics returns Prometheus format
  • Verify n8n workflow JSON imports into n8n instance
  • Check deploy.sh files are executable (ls -la agents/*/deploy.sh)
  • Confirm deploy-defense.yml contains all three secret references and full 4-job workflow

🤖 Generated with Claude Code

romanchaa997 and others added 30 commits March 11, 2026 20:19
Defines risk rules for the AuditorSEC Defense Audit Platform, including various categories and severity levels. Implements a function to run audits based on CSV data and calculate risk scores.

Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
…tegration

This workflow automates the deployment of the AuditorSEC Defense application to Railway, including steps for type checking, building and pushing a Docker image, deploying, and performing health checks.

Signed-off-by: Igor <romanchaa997@gmail.com>
Added comprehensive BRAVE1 Grant Master Plan detailing project scope, budget, timeline, compliance, and actionable tasks.

Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
Added a new dashboard for AuditorSEC BRAVE1 Grant KPIs including various compliance metrics.

Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
…peScript Check job

Signed-off-by: Igor <romanchaa997@gmail.com>
…typecheck job

Signed-off-by: Igor <romanchaa997@gmail.com>
…plicate workflow

- Dockerfile: resolved merge conflict, production multi-stage build on :5000
- docker-compose.yml: resolved merge conflict, full observability stack
- Removed railway-deploy.yml (duplicate of deploy-defense.yml)
- Added brave1-kpis.json Grafana dashboard for BRAVE1 grant KPIs
- Added Grafana provisioning (datasource + dashboard auto-import)
- Fixed Prometheus scrape targets for defense app on port 5000

BRAVE1 audit trail: fixes for CI pipeline and monitoring stack
…rics check

- Regenerate package-lock.json to fix npm ci failures (stale lockfile)
- Add express and prom-client to dependencies (required by src/metrics.ts)
- Fix deploy-defense.yml: correct metrics grep from audit_duration_seconds
  to audityzer_audits_total, add RAILWAY_PROJECT_ID env var
- Add grafana/datasources/prometheus.yml for auto-provisioning
- Expand BRAVE1 KPI dashboard from 3 to 8 panels (all Prometheus metrics)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Master orchestration-spec.yaml: 4-stage pipeline (CSV → ClickUp → GitHub Actions → Railway/Prometheus/Grafana → BRAVE1)
- n8n workflows: defense-audit-deploy, brave1-auto-submit, telegram-self-healing
- Zapier specs: 3 zaps for ClickUp↔GitHub↔Grafana↔BRAVE1 integration
- GitHub Actions: self-healing CI (lockfile regen) + BRAVE1 weekly KPI export
- Full README documenting all automation components and required secrets

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Expanded README with ASCII architecture diagram, full component documentation,
Prometheus KPI table, setup instructions, and BRAVE1 integration details.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… cache

Fixes 3+ hour npm install hang. The typecheck job only needs type-checking,
not browser binaries. Also adds setup-node cache for faster subsequent runs.
Docker COPY does not support '2>/dev/null || true' — those are shell constructs.
Docker was interpreting '||' and '2>/dev/null' as literal filenames, causing:
  ERROR: failed to calculate checksum of ref: "/||" not found

Replaced with direct COPY commands (all dirs exist in repo) and ensured
dist/ is always created in builder stage.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Added Express server (server.js) for Railway with:
  - /health endpoint for Railway healthchecks
  - /api/ai/detect POST endpoint (pattern + HF CodeBERT)
  - /api/status platform status
  - /api/rules security rules list
  - Static file serving (dist/ or public/ fallback)
- Updated ai-vulnerability-detection.js with HF Inference API integration
  - microsoft/codebert-base for code embedding analysis
  - 7 vulnerability pattern categories (reentrancy, access control, overflow, flash loan, front-running, cross-chain, oracle)
- Updated railway.json: startCommand -> node server.js
- Added cors dependency
…elegram 5-step pipeline

- pipedream-risk-router.js: Full 5-step workflow (normalize, clickup, github, telegram, audityzer)
- monday-webhook-setup.md: Webhook configuration guide
- README.md: Environment vars and setup instructions
- Dual thresholds: Enterprise (11/5) vs SMB (13/7) risk scoring
- Backend risk recalculation as verification layer
…kUp Risk Register

- setup-monday-columns.js: Creates 7 columns (Sentiment, Likelihood, Impact, Days Overdue, Days No Touch, Risk Score, Risk Level) with formulas via GraphQL API
- setup-clickup-risk-register.js: Creates Risk Register list with 11 custom fields + sample task
- setup-all.sh: One-click runner for both
- README.md: Quick-start guide + architecture reference

Run: MONDAY_API_TOKEN=xxx CLICKUP_API_TOKEN=yyy ./setup-all.sh
@railway-app railway-app Bot temporarily deployed to strong-healing / production April 5, 2026 03:49 Inactive
@railway-app railway-app Bot temporarily deployed to audityzer-master-admin / production April 5, 2026 03:49 Inactive
…134)

Updated the deploy script to use environment variables for sensitive credentials and improved output messages.

Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
…check /health

Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
Signed-off-by: Igor <romanchaa997@gmail.com>
This workflow automates the process of merging the main branch into the defense-audit branch and regenerates the package-lock.json if necessary.

Signed-off-by: Igor <romanchaa997@gmail.com>
@romanchaa997
Copy link
Copy Markdown
Owner Author

🔗 Stream D — Parallel Integrations Status (Sprint 260h | 19.04.2026)

PR #125 — 80 commits, 117 files | GHA sync + Grafana + n8n + agents scaffold + secrets

Integration Components:

  • ✅ GHA workflow sync (parallel task dispatch)
  • ✅ Grafana metrics dashboard config (grafana/)
  • ✅ Prometheus scrape config
  • ✅ n8n automation workflow scaffold
  • ✅ GitHub Secrets for all API keys (OPENAI, MINIO, OPTIMISM_RPC)
  • ✅ Agents scaffold: VulnScan / Compliance / PQC / Report pipeline

New complementary PRs (Sprint 260h):

🔗 PR Merge Order (Critical Path):

PR #176 → safe-improvements (merged first)
PR #177 → safe-improvements
PR #178 → safe-improvements
PR #179 → safe-improvements
PR #174 → safe-improvements
PR #153 [CRITICAL] → main (bypass branch protection needed)
  └→ PR #132 → main
  └→ PR #125 → main (this PR — after #153 merges)

Required Secrets (add to GitHub + Railway):

OPENAI_API_KEY=sk-...
MINIO_ENDPOINT=minio:9000
MINIO_ACCESS_KEY=...
MINIO_SECRET_KEY=...
MINIO_BUCKET=audit-reports
OPTIMISM_RPC_URL=https://mainnet.optimism.io

Estimated merge: Wednesday 23.04 (after #153 conflict resolution)

@romanchaa997
Copy link
Copy Markdown
Owner Author

PR Review — #125: feat: parallel API integrations (GHA sync, Grafana, metrics, n8n, agents scaffold, secrets)

Status: Open — 80 commits from defense-auditsafe-improvements. Open for 2 weeks.

Scope: Parallel API integrations including GHA sync, Grafana dashboards, metrics pipeline, n8n workflow automation, AI agents scaffolding, and secrets management. This targets safe-improvements (not main directly), making it a precursor to PR #153.

Key observations:

  • 80 commits targeting safe-improvements — significant feature set
  • 6 open task checklist items indicate incomplete work
  • 112 conversation comments — very actively discussed
  • 2 weeks old — check for potential conflicts with the current state of safe-improvements

Relationship to other PRs:

Recommendation:

  1. Complete the 6 remaining task checklist items
  2. Check for conflicts with the current safe-improvements branch state
  3. Review and resolve the open conversation threads (112 comments)
  4. Once all tasks are done, merge this before or alongside the other safe-improvements PRs

Replaced pnpm with npm for dependency installation and build steps.

Signed-off-by: Igor <romanchaa997@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants