Skip to content

feat: Add Helm chart and release workflow for ncps - #402

Merged
kalbasit merged 1 commit into
mainfrom
k8s-helm-chart
Jan 2, 2026
Merged

kalbasit merged 1 commit into
mainfrom
k8s-helm-chart

Conversation

@kalbasit

@kalbasit kalbasit commented Jan 1, 2026

Copy link
Copy Markdown
Owner

Add Helm Chart for ncps (Nix Cache Proxy Server)

This PR adds a comprehensive Helm chart for deploying ncps (Nix Cache Proxy Server) on Kubernetes. The chart supports both single-instance and high-availability deployments with various configuration options.

Key features:

  • Flexible deployment options (Deployment or StatefulSet)
  • Multiple storage backends (local filesystem or S3)
  • Database options (SQLite, PostgreSQL, MySQL)
  • High-availability mode with Redis-based distributed locking
  • Prometheus metrics and ServiceMonitor integration
  • Ingress configuration with TLS support
  • Comprehensive documentation and examples

The PR also adds a GitHub workflow for automated Helm chart releases, which:

  • Triggers on helm-v* tags
  • Updates chart version based on tag
  • Packages and publishes the chart to GitHub Container Registry
  • Creates a GitHub release with installation instructions

Additionally, the PR updates the Claude settings to allow Helm-related commands and updates the YAML formatting configuration to reference the new chart directory.

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @kalbasit, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request significantly enhances the operational capabilities of the Nix Cache Proxy Server (ncps) by introducing a robust Helm chart. This allows users to easily deploy, configure, and manage ncps instances within a Kubernetes environment, supporting diverse storage and database needs, and enabling high-availability setups. The addition of an automated release workflow streamlines the distribution and versioning of the Helm chart, making it more accessible and maintainable for the community.

Highlights

  • Helm Chart Introduction: A comprehensive Helm chart has been added for deploying the Nix Cache Proxy Server (ncps) on Kubernetes, enabling flexible and scalable deployments.
  • Deployment Flexibility: The chart supports both single-instance and high-availability (HA) deployments, offering options for local filesystem or S3 storage, and various database backends including SQLite, PostgreSQL, and MySQL.
  • High-Availability Features: For HA deployments, the chart integrates Redis for distributed locking and includes validation logic to prevent incompatible configurations like using SQLite or local storage with HA deployments.
  • Observability and Networking: Prometheus metrics and ServiceMonitor integration are included for monitoring, along with configurable Ingress support for exposing ncps with TLS.
  • Automated Release Workflow: A new GitHub workflow automates Helm chart releases, triggering on helm-v* tags, updating chart versions, packaging, publishing to GitHub Container Registry, and creating GitHub releases.
  • Tooling Integration: Updates were made to Claude settings to allow Helm-related commands and to .yamlfmt.yml to correctly reference the new chart directory.
Ignored Files
  • Ignored by pattern: .github/workflows/** (1)
    • .github/workflows/helm-release.yaml
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩

@dosubot

dosubot Bot commented Jan 1, 2026 •

Copy link
Copy Markdown

Related Documentation

Checked 7 published document(s) in 1 knowledge base(s). No updates required.

How did I do? Any feedback?  Join Discord

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This is an excellent and comprehensive Helm chart for ncps. The structure, documentation, and use of modern Helm features like values.schema.json and validation helpers are all best practices. I've found one critical issue in the configmap.yaml related to how upstream public keys are configured, which would prevent the chart from working correctly. I also have a suggestion to improve the documentation in the README.md by removing hardcoded release names from example commands. Overall, great work!

Comment thread charts/ncps/templates/configmap.yaml Resolved
Comment thread charts/ncps/README.md Resolved
@kalbasit
kalbasit changed the base branch from formatter-support-helm to graphite-base/402 January 1, 2026 00:50
@kalbasit
kalbasit changed the base branch from graphite-base/402 to main January 1, 2026 00:50

kalbasit commented Jan 1, 2026

Copy link
Copy Markdown
Owner Author

/gemini review

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request introduces a comprehensive Helm chart for ncps, including templates for Deployment and StatefulSet modes, various storage and database backends, and a release workflow. The chart is well-structured with extensive documentation, examples, and validation. My review focuses on ensuring the Helm templates are robust and correctly implemented. I've identified a couple of issues: a high-severity issue with a hardcoded port that could break deployments with custom configurations, and a medium-severity issue where the PodDisruptionBudget feature is defined but not implemented. Overall, this is an excellent contribution that significantly improves the deployability of ncps.

Comment thread charts/ncps/templates/deployment.yaml Resolved
Comment thread charts/ncps/templates/statefulset.yaml Resolved
Comment thread charts/ncps/values.schema.json Resolved
@kalbasit
kalbasit changed the base branch from main to graphite-base/402 January 1, 2026 02:52
@kalbasit
kalbasit changed the base branch from graphite-base/402 to script-k8s-cluster January 1, 2026 02:52
@kalbasit
kalbasit force-pushed the script-k8s-cluster branch from 6ba9a0a to 195d1c6 Compare January 1, 2026 03:58
@kalbasit
kalbasit force-pushed the script-k8s-cluster branch from 195d1c6 to 72329dd Compare January 1, 2026 04:20
@kalbasit
kalbasit changed the base branch from script-k8s-cluster to graphite-base/402 January 1, 2026 04:55
@kalbasit
kalbasit changed the base branch from graphite-base/402 to add-standard-user January 1, 2026 04:55
@kalbasit
kalbasit force-pushed the add-standard-user branch 2 times, most recently from b72e448 to 6798b0f Compare January 1, 2026 05:31

kalbasit commented Jan 2, 2026

Copy link
Copy Markdown
Owner Author

/gemini review

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request introduces a comprehensive and well-structured Helm chart for ncps. The chart is feature-rich, supporting various deployment modes, storage backends, and database options. The inclusion of detailed documentation in the README.md, NOTES.txt, and a values.schema.json is excellent and will greatly benefit users. The validation logic in _helpers.tpl is robust and helps prevent common misconfigurations.

I've found a critical issue related to how secret keys are referenced in deployment.yaml and statefulset.yaml, which would prevent pods from starting when using external secrets. I've also provided suggestions to improve the troubleshooting documentation and make the Helm tests more deterministic.

Overall, this is a high-quality contribution. Once the critical issue is addressed, this chart will be in great shape.

Comment thread charts/ncps/templates/deployment.yaml Resolved
Comment thread charts/ncps/templates/statefulset.yaml Resolved
Comment thread charts/ncps/README.md Resolved
@kalbasit
kalbasit force-pushed the add-job-for-helm-chart branch 2 times, most recently from 6ecff77 to e2115d7 Compare January 2, 2026 05:06
@kalbasit
kalbasit force-pushed the k8s-helm-chart branch 2 times, most recently from e431ecd to 069d101 Compare January 2, 2026 05:06
@kalbasit
kalbasit force-pushed the add-job-for-helm-chart branch from e2115d7 to 1a0ecf5 Compare January 2, 2026 05:32
@kalbasit
kalbasit force-pushed the add-job-for-helm-chart branch from 1a0ecf5 to 9a83d9e Compare January 2, 2026 05:44
@kalbasit
kalbasit force-pushed the add-job-for-helm-chart branch 2 times, most recently from 4ba61bc to 73c2035 Compare January 2, 2026 05:55
@kalbasit
kalbasit changed the base branch from add-job-for-helm-chart to graphite-base/402 January 2, 2026 06:05
@kalbasit
kalbasit changed the base branch from graphite-base/402 to main January 2, 2026 06:06
@kalbasit
kalbasit merged commit f2356c8 into main Jan 2, 2026

kalbasit commented Jan 2, 2026

Copy link
Copy Markdown
Owner Author

Merge activity

@kalbasit
kalbasit deleted the k8s-helm-chart branch January 2, 2026 06:17
@kalbasit kalbasit added this to the v0.6.0 - High Availability milestone Jan 5, 2026
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