Skip to content

Conversation

@Flo4604
Copy link
Member

@Flo4604 Flo4604 commented Dec 2, 2025

What does this PR do?

This currently just straight up injects the env vars into the pod and container.

A downside of this is that if you do kubectl describe pod whatever-pod-name values are shown in plain secret.
We can work-around this using kubectl create secret generic and then using rbac to access who can and can't look at secrets but they are still stored as base64...

There are a few other versions on how we could inject this to only make it be shown in the pod process such as

  • a CSI driver, which decrypts them in a extra kubernetes plugin and will then mount the secrets as a volume.
    downside here is that we'd need to wrap the entrypoint to set them as an actual env var which im not a fan of.

If there is not an issue for this, please create one first. This is used to tracking purposes and also helps us understand why this PR exists

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • Chore (refactoring code, technical debt, workflow improvements)
  • Enhancement (small improvements)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How should this be tested?

  • Test A
  • Test B

Checklist

Required

  • Filled out the "How to test" section in this PR
  • Read Contributing Guide
  • Self-reviewed my own code
  • Commented on my code in hard-to-understand areas
  • Ran pnpm build
  • Ran pnpm fmt
  • Ran make fmt on /go directory
  • Checked for warnings, there are none
  • Removed all console.logs
  • Merged the latest changes from main onto my branch with git pull origin main
  • My changes don't cause any responsiveness issues

Appreciated

  • If a UI change was made: Added a screen recording or screenshots to this PR
  • Updated the Unkey Docs if changes were necessary

@changeset-bot
Copy link

changeset-bot bot commented Dec 2, 2025

⚠️ No Changeset found

Latest commit: 469e267

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link

vercel bot commented Dec 2, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
dashboard Error Error Dec 9, 2025 4:17pm
1 Skipped Deployment
Project Deployment Preview Comments Updated (UTC)
engineering Ignored Ignored Preview Dec 9, 2025 4:17pm

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 2, 2025

Warning

Rate limit exceeded

@chronark has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 26 minutes and 49 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.

📥 Commits

Reviewing files that changed from the base of the PR and between 5f2bcf8 and 469e267.

⛔ Files ignored due to path filters (2)
  • apps/dashboard/gen/proto/krane/v1/deployment_pb.ts is excluded by !**/gen/**
  • go/gen/proto/krane/v1/deployment.pb.go is excluded by !**/*.pb.go, !**/gen/**
📒 Files selected for processing (3)
  • go/apps/krane/backend/docker/deployment_create.go (2 hunks)
  • go/apps/krane/backend/kubernetes/deployment_create.go (2 hunks)
  • go/proto/krane/v1/deployment.proto (1 hunks)
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/env-vars-krane-injection

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.

@Flo4604 Flo4604 force-pushed the feat/env-vars-krane-injection branch from ad029dc to ca3d3e9 Compare December 2, 2025 13:57
@Flo4604 Flo4604 force-pushed the feat/env-vars-ctrl-decryption branch from 66f4d6a to b656788 Compare December 2, 2025 13:57
@Flo4604 Flo4604 force-pushed the feat/env-vars-ctrl-decryption branch from b656788 to ddcd457 Compare December 2, 2025 14:06
@Flo4604 Flo4604 force-pushed the feat/env-vars-krane-injection branch from ca3d3e9 to 5cebd23 Compare December 2, 2025 14:06
@Flo4604 Flo4604 force-pushed the feat/env-vars-krane-injection branch from 5cebd23 to fb9553e Compare December 2, 2025 14:13
@Flo4604 Flo4604 force-pushed the feat/env-vars-ctrl-decryption branch from ddcd457 to b3eac6f Compare December 2, 2025 14:13
@Flo4604 Flo4604 force-pushed the feat/env-vars-ctrl-decryption branch from b3eac6f to df024e6 Compare December 2, 2025 14:42
@Flo4604 Flo4604 force-pushed the feat/env-vars-krane-injection branch from fb9553e to d343085 Compare December 2, 2025 14:42
@Flo4604 Flo4604 force-pushed the feat/env-vars-ctrl-decryption branch from df024e6 to 6c33142 Compare December 2, 2025 15:47
@Flo4604 Flo4604 force-pushed the feat/env-vars-krane-injection branch from d343085 to fdee599 Compare December 2, 2025 15:47
@Flo4604 Flo4604 force-pushed the feat/env-vars-krane-injection branch from ce78cee to b071965 Compare December 4, 2025 17:36
@Flo4604 Flo4604 force-pushed the feat/env-vars-ctrl-decryption branch from 974e517 to 9adddc0 Compare December 4, 2025 17:36
@Flo4604 Flo4604 mentioned this pull request Dec 4, 2025
19 tasks
Base automatically changed from feat/env-vars-ctrl-decryption to main December 9, 2025 16:13
@chronark chronark merged commit 569a89d into main Dec 9, 2025
9 of 11 checks passed
@chronark chronark deleted the feat/env-vars-krane-injection branch December 9, 2025 16:15
mcstepp pushed a commit that referenced this pull request Dec 9, 2025
* feat: add environment variables db schema and queries

* fix db query

* feat: add SecretsConfig proto for encrypted env vars

* [autofix.ci] apply automated fixes

* feat: dashboard UI for environment variables management

* fix comment and rename file

* fix file export name

* Remove unnecessary comments from add-env-vars

* add toasts for environment variable operations

* [autofix.ci] apply automated fixes

* fix: add try/catch error handling to env var mutations

* unfmt file

* [autofix.ci] apply automated fixes

* feat: decrypt env vars in CTRL workflow before passing to Krane

* feat: inject env vars into pod spec via Krane

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Andreas Thomas <[email protected]>
Flo4604 added a commit that referenced this pull request Dec 10, 2025
* feat: add environment variables db schema and queries

* fix db query

* feat: add SecretsConfig proto for encrypted env vars

* [autofix.ci] apply automated fixes

* feat: dashboard UI for environment variables management

* fix comment and rename file

* fix file export name

* Remove unnecessary comments from add-env-vars

* add toasts for environment variable operations

* [autofix.ci] apply automated fixes

* fix: add try/catch error handling to env var mutations

* unfmt file

* [autofix.ci] apply automated fixes

* feat: decrypt env vars in CTRL workflow before passing to Krane

* feat: inject env vars into pod spec via Krane

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Andreas Thomas <[email protected]>
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.

3 participants