Skip to content

add sops example#412

Merged
mrshmllow merged 4 commits intotrunkfrom
marshmallow/p-wwmsppltyrxv
Mar 26, 2026
Merged

add sops example#412
mrshmllow merged 4 commits intotrunkfrom
marshmallow/p-wwmsppltyrxv

Conversation

@mrshmllow
Copy link
Copy Markdown
Member

@mrshmllow mrshmllow commented Mar 26, 2026

closes #386

Summary by CodeRabbit

  • Documentation
    • Added SOPS as a supported non-interactive key source alongside GPG and Age.
    • Added an "Encrypting with Sops" subsection with a sample encrypted YAML secrets structure and guidance for extracting values.
    • Included a reusable example showing how to decrypt a SOPS file and extract multiple secret outputs for deployment use.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 26, 2026

Warning

Rate limit exceeded

@mrshmllow has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 2 minutes and 0 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, 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 have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: d3b15c34-6dc3-40e6-94db-0138008568f3

📥 Commits

Reviewing files that changed from the base of the PR and between cd89d14 and 78e1b42.

📒 Files selected for processing (1)
  • doc/guides/keys.md
📝 Walkthrough

Walkthrough

Documentation now lists SOPS as a supported non-interactive key source and a new Nix snippet demonstrates decrypting a SOPS-encrypted YAML and mapping extracted values into Hive deployment keys.

Changes

Cohort / File(s) Summary
SOPS guide
doc/guides/keys.md
Added sops to the list of supported non-interactive key sources and a "Encrypting with Sops" subsection with a sample secret.yaml layout and a link to the new Nix snippet.
SOPS example snippet
doc/snippets/guides/sops-example.nix
New Nix example that imports pinned inputs, constructs a wire.makeHive config, defines mkSops to build a sops decrypt + extraction command for a key path, and maps two deployment outputs (some_secret.txt, another_secret.txt) to mkSops calls.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🐰 I nibble keys beneath the moon,

SOPS hums softly, secrets croon.
From YAML burrows, bits take flight,
I hop with treasures, snug and light.
Hoppity-hop — encrypted delight. 🥕🔐

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'add sops example' directly and accurately describes the main change: adding a SOPS example to the documentation.
Linked Issues check ✅ Passed The PR adds a SOPS example as required by issue #386, including documentation and a Nix snippet demonstrating SOPS integration.
Out of Scope Changes check ✅ Passed All changes are directly related to adding SOPS documentation and examples as specified in issue #386; no out-of-scope modifications detected.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch marshmallow/p-wwmsppltyrxv

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

@github-actions github-actions Bot added documentation Improvements or additions to documentation nix Pull requests that update nix. release PRs against main labels Mar 26, 2026
@mrshmllow mrshmllow enabled auto-merge (squash) March 26, 2026 04:18
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@doc/guides/keys.md`:
- Around line 194-204: The YAML example header is labeled "secret.yaml" but the
snippet include references "../secrets.yaml", causing a mismatch; update either
the code fence label or the snippet include so both use the same filename (e.g.,
change the code fence to "secrets.yaml" or the snippet include to
"@/snippets/guides/sops-example.nix [secret.nix]"/ "../secret.yaml") so the
sample and the include are consistent; adjust the label in the YAML block or the
path in the snippet include (search for the "secret.yaml" code fence and the
"@/snippets/guides/sops-example.nix [hive.nix]" include) and make their
filenames identical.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 822e2b0d-7235-4df6-9c8e-df5d45885f3c

📥 Commits

Reviewing files that changed from the base of the PR and between bf3e31b and 585fb0f.

📒 Files selected for processing (2)
  • doc/guides/keys.md
  • doc/snippets/guides/sops-example.nix

Comment thread doc/guides/keys.md Outdated
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
doc/guides/keys.md (1)

100-110: Polish wording/capitalization in the new SOPS section.

Consider changing With some sops file: to With a SOPS file like: for clearer phrasing and consistent naming.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@doc/guides/keys.md` around lines 100 - 110, Replace the heading phrase "With
some sops file:" in the new SOPS section with the clearer wording "With a SOPS
file like:" and ensure "SOPS" is capitalized consistently throughout that
paragraph (and similar nearby occurrences) to match project naming conventions;
locate the exact string "With some sops file:" in the doc/guides/keys.md diff
and update it to the suggested phrase.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@doc/guides/keys.md`:
- Line 21: The in-page anchor `[Example](`#with-sops`)` doesn't match the actual
SOPS example heading; locate the SOPS example heading (e.g., the "With SOPS" or
"With sops" heading) and update the link to use the exact markdown-generated
slug for that heading (lowercase, spaces → hyphens), or add an explicit HTML
anchor above the heading (e.g., `<a id="with-sops"></a>`) so the existing
`[Example](`#with-sops`)` resolves correctly; adjust the link or anchor near the
heading and keep the link text `[Example](`#with-sops`)` consistent.

---

Nitpick comments:
In `@doc/guides/keys.md`:
- Around line 100-110: Replace the heading phrase "With some sops file:" in the
new SOPS section with the clearer wording "With a SOPS file like:" and ensure
"SOPS" is capitalized consistently throughout that paragraph (and similar nearby
occurrences) to match project naming conventions; locate the exact string "With
some sops file:" in the doc/guides/keys.md diff and update it to the suggested
phrase.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: aea96084-0861-46a7-8442-3f4458d1bdfc

📥 Commits

Reviewing files that changed from the base of the PR and between 4754b94 and cd89d14.

📒 Files selected for processing (1)
  • doc/guides/keys.md

Comment thread doc/guides/keys.md Outdated
@mrshmllow mrshmllow disabled auto-merge March 26, 2026 04:35
@mrshmllow mrshmllow merged commit b152eac into trunk Mar 26, 2026
17 checks passed
@mrshmllow mrshmllow deleted the marshmallow/p-wwmsppltyrxv branch March 26, 2026 04:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation nix Pull requests that update nix. release PRs against main

Projects

None yet

Development

Successfully merging this pull request may close these issues.

task: add sops example

1 participant