Skip to content

armgit / AiSOC

Public Imported from GitHub
0

Open-source AI Security Operations Center: alert fusion, LLM-agent triage, MITRE ATT&CK investigation, and a replayable decision ledger for every agent step. Self-hostable, runs with no API keys, MIT licensed. Ships an MCP server for Claude, Cursor and Continue.

fix(scheduler-lease-live): run the suite as the runtime role

Beenu Aroradc07b8762389
diff --git a/.github/workflows/scheduler-lease-live.yml b/.github/workflows/scheduler-lease-live.yml
index a52cfa99c..72bd7e96d 100644
--- a/.github/workflows/scheduler-lease-live.yml
+++ b/.github/workflows/scheduler-lease-live.yml
@@ -47,7 +47,12 @@ jobs:
--health-retries 20
env:
- LEASE_DSN: postgresql+asyncpg://aisoc:aisoc_ci_only@localhost:5432/aisoc
+ # The runtime role, not the owner. A superuser ignores every RLS
+ # policy in the schema, and although scheduler_leases carries none
+ # by design — it is replica coordination, not tenant data — running
+ # a live suite as the superuser is how a tree acquires the habit.
+ LEASE_DSN: postgresql+asyncpg://aisoc_app:aisoc_app_ci_only@localhost:5432/aisoc
+ LEASE_DATABASE_MIGRATION_URL: postgresql+asyncpg://aisoc:aisoc_ci_only@localhost:5432/aisoc
PGPASSWORD: aisoc_ci_only
ENVIRONMENT: test
OTEL_SDK_DISABLED: "true"
@@ -79,6 +84,14 @@ jobs:
psql -h localhost -U aisoc -d aisoc -v ON_ERROR_STOP=1 -q -f "$f"
done
+ - name: Give the runtime role its password
+ run: |
+ set -euo pipefail
+ psql -h localhost -U aisoc -d aisoc -v ON_ERROR_STOP=1 -q -c \
+ "ALTER ROLE aisoc_app WITH PASSWORD 'aisoc_app_ci_only';"
+ psql -h localhost -U aisoc -d aisoc -v ON_ERROR_STOP=1 -q -c \
+ "GRANT USAGE ON SCHEMA public TO aisoc_app;"
+
- name: The lease table exists
run: |
set -euo pipefail