Skip to content

docs: make cloud-sink examples runnable standalone via docker-compose - #947

Merged
scarmuega merged 2 commits into
mainfrom
examples/standalone-compose
Jun 15, 2026
Merged

docs: make cloud-sink examples runnable standalone via docker-compose#947
scarmuega merged 2 commits into
mainfrom
examples/standalone-compose

Conversation

@scarmuega

Copy link
Copy Markdown
Member

What

Adds a docker-compose.yml to each cloud-sink example so it runs without a real cloud account, and documents the standalone workflow in each README. Builds on the recent per-example READMEs (#943).

Example Standalone backend Verified
aws_s3 LocalStack + init creating my-bucket ✅ object written to s3://my-bucket/mainnet/
aws_sqs LocalStack + init creating my-queue ✅ messages enqueued
aws_lambda LocalStack + a tiny deployed function (mounts Docker socket) lambda.Invoke => 200
gcp_pubsub Pub/Sub emulator + init creating topic & subscription ✅ message pulled from subscription
gcp_cloudfunction http-echo server (a Cloud Function is just an HTTP endpoint) ✅ POSTs received
webhook_basics http-echo server ✅ POSTs received

Each README gains Run standalone and Run against real <cloud> sections. The AWS/GCP SDKs honor AWS_ENDPOINT_URL / PUBSUB_EMULATOR_HOST, so no Oura code changes are needed — the READMEs show the env vars to point at the local emulators. All six were verified end-to-end against the bundled services.

Config changes

  • aws_s3/daemon.toml — bug fix: the AwsS3 sink only accepts Record::CborBlock, but the example ran a ParseCbor filter, so it errored on the first block ("Invalid configuration daemon") regardless of AWS. Removed the filter — N2N already emits CborBlock.
  • aws_sqs/daemon.tomlqueue_url now points at the bundled LocalStack queue (real-AWS form kept in a comment), matching how the kafka/redis/postgres examples target their bundled service.
  • gcp_cloudfunction/daemon.tomlurl = http://localhost:8080 + authentication = false for the local echo server (the identity-token path needs real Google credentials; documented for real GCP).

Notes

Examples left without a bundled service on purpose: dolos_source / hydra (need a synced chain / live Hydra head), mithril (public remote aggregator), zeromq (sink connects a PUSH socket, so the peer must bind PULL — no off-the-shelf image).

🤖 Generated with Claude Code

scarmuega and others added 2 commits June 14, 2026 21:36
Bump cargo-dist to 0.30.3 and adjust its config:

- install-updater = false: stop bundling the axoupdate self-updater in
  the generated installers.
- pr-run-mode = "skip": don't run the release dry-run on pull requests
  (PR validation already lives in ci.yml); the release workflow now fires
  only on version tags.

release.yml is regenerated from dist-workspace.toml accordingly.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add a docker-compose.yml to each cloud-sink example so it runs with no real
cloud account, and document the standalone workflow in each README:

- aws_s3 / aws_sqs / aws_lambda — LocalStack + an init script that provisions
  the bucket / queue / function. The AWS SDK honors AWS_ENDPOINT_URL, so no
  code change is needed; the READMEs show the env vars to target LocalStack.
- gcp_pubsub — Google's Pub/Sub emulator + a curl init container creating the
  topic and a subscription. Targeted via PUBSUB_EMULATOR_HOST.
- gcp_cloudfunction / webhook_basics — an http-echo server stands in for the
  HTTP endpoint.

Each README gains "Run standalone" and "Run against real <cloud>" sections.
All six were verified end-to-end against the bundled services.

Also fix a pre-existing bug in aws_s3/daemon.toml: the AwsS3 sink only accepts
Record::CborBlock, but the example ran a ParseCbor filter, so it errored on the
first block regardless of AWS. Removed the filter (N2N already emits CborBlock).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@scarmuega
scarmuega requested a review from paulobressan as a code owner June 15, 2026 00:39
@coderabbitai

coderabbitai Bot commented Jun 15, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@scarmuega, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 22 minutes. Learn how PR review limits work.

Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file).

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 56de27a8-71d2-4993-a96d-cb9433414a1c

📥 Commits

Reviewing files that changed from the base of the PR and between fcb60cc and ffef1b1.

📒 Files selected for processing (21)
  • .github/workflows/release.yml
  • dist-workspace.toml
  • examples/aws_lambda/README.md
  • examples/aws_lambda/docker-compose.yml
  • examples/aws_lambda/localstack/handler.py
  • examples/aws_lambda/localstack/init.sh
  • examples/aws_s3/README.md
  • examples/aws_s3/daemon.toml
  • examples/aws_s3/docker-compose.yml
  • examples/aws_s3/localstack/init.sh
  • examples/aws_sqs/README.md
  • examples/aws_sqs/daemon.toml
  • examples/aws_sqs/docker-compose.yml
  • examples/aws_sqs/localstack/init.sh
  • examples/gcp_cloudfunction/README.md
  • examples/gcp_cloudfunction/daemon.toml
  • examples/gcp_cloudfunction/docker-compose.yml
  • examples/gcp_pubsub/README.md
  • examples/gcp_pubsub/docker-compose.yml
  • examples/webhook_basics/README.md
  • examples/webhook_basics/docker-compose.yml
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch examples/standalone-compose

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@scarmuega
scarmuega merged commit 86bc1ed into main Jun 15, 2026
5 checks passed
@scarmuega
scarmuega deleted the examples/standalone-compose branch June 15, 2026 00:39
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.

1 participant