From e9e6b1642a538601ec9375185078b18e1f5f5c77 Mon Sep 17 00:00:00 2001 From: O M Date: Mon, 12 Oct 2026 20:40:32 -0400 Subject: [PATCH 1/2] Document that the API image build needs 6 GiB of Docker memory. Co-authored-by: Cursor --- CONTRIBUTING.md | 2 +- README.md | 2 ++ docker-compose.yml | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index b17a6c5..28d63b9 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -11,7 +11,7 @@ Thank you for helping build open cloud security tooling. 1. Fork and clone the repo 2. Copy `.env.example` to `.env` -3. Run `docker compose up -d` for local Postgres +3. Run `docker compose up -d` for local Postgres and the API. Give Docker at least 6 GiB of RAM so the API image build can finish. 4. Pick an [open issue](https://github.com/OpenSourceOM/core/issues) or an item from [docs/ROADMAP.md](./docs/ROADMAP.md). For a change that is not tracked yet, open a [discussion](https://github.com/OpenSourceOM/core/discussions) with the `roadmap` label. ## Pull request reviews diff --git a/README.md b/README.md index a8e0e37..d1d7dd6 100644 --- a/README.md +++ b/README.md @@ -120,6 +120,8 @@ go build -o example-collector ./examples/collector open http://localhost:8080 ``` +The API image compiles `github.com/aws/aws-sdk-go-v2/service/ec2`. Give Docker at least 6 GiB of RAM. With 2 GiB the Go compiler is killed and the build stops at `compile: signal: killed`. On Colima: `colima start --cpu 4 --memory 6`. + `.env.example` sets `OM_API_SECRET=change-me-in-production`, and Compose passes that into the API. In the console, paste that value into the API key field and click **Save API key**. The console then sends it as `X-API-Key` on every `/v1` call except health. Leave the secret empty to keep local API calls open. **API endpoints:** `GET /v1/health`, `POST /v1/ingest`, `GET /v1/findings`, `GET /v1/graph/snapshot`, `POST /v1/rules/run`, `GET /v1/identity/blast-radius` diff --git a/docker-compose.yml b/docker-compose.yml index 36ef57e..ddb6e97 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -2,6 +2,8 @@ # SPDX-License-Identifier: Apache-2.0 # Local dev stack: Postgres + API # Usage: cp .env.example .env && docker compose up -d +# The API image compiles aws-sdk-go-v2/service/ec2. Docker needs at least 6 GiB +# of RAM; 2 GiB kills the compiler (`compile: signal: killed`). services: postgres: From 51f6880789d17e4661214391a8ecb833e971cc6a Mon Sep 17 00:00:00 2001 From: O M Date: Mon, 12 Oct 2026 20:44:09 -0400 Subject: [PATCH 2/2] Shorten the Docker memory note. Co-authored-by: Cursor --- README.md | 2 +- docker-compose.yml | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index d1d7dd6..77f3d2f 100644 --- a/README.md +++ b/README.md @@ -120,7 +120,7 @@ go build -o example-collector ./examples/collector open http://localhost:8080 ``` -The API image compiles `github.com/aws/aws-sdk-go-v2/service/ec2`. Give Docker at least 6 GiB of RAM. With 2 GiB the Go compiler is killed and the build stops at `compile: signal: killed`. On Colima: `colima start --cpu 4 --memory 6`. +The API image compiles `github.com/aws/aws-sdk-go-v2/service/ec2`. Give Docker at least 6 GiB of RAM. `.env.example` sets `OM_API_SECRET=change-me-in-production`, and Compose passes that into the API. In the console, paste that value into the API key field and click **Save API key**. The console then sends it as `X-API-Key` on every `/v1` call except health. Leave the secret empty to keep local API calls open. diff --git a/docker-compose.yml b/docker-compose.yml index ddb6e97..33ae81b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -2,8 +2,7 @@ # SPDX-License-Identifier: Apache-2.0 # Local dev stack: Postgres + API # Usage: cp .env.example .env && docker compose up -d -# The API image compiles aws-sdk-go-v2/service/ec2. Docker needs at least 6 GiB -# of RAM; 2 GiB kills the compiler (`compile: signal: killed`). +# The API image compiles aws-sdk-go-v2/service/ec2. Docker needs at least 6 GiB of RAM. services: postgres: