Skip to content

Conversation

@arikalon1
Copy link
Contributor

allow overriding the kubectl image

allow overriding the kubectl image
@arikalon1 arikalon1 requested a review from aantn October 8, 2025 18:11
@coderabbitai
Copy link

coderabbitai bot commented Oct 8, 2025

Walkthrough

Bumps Helm chart and app versions to 0.3.4. Introduces configurable cert job image and a toggle to install OpenSSL during the certificate job. Updates the job template to use values-driven image and conditionally install OpenSSL before running the existing certificate generation steps.

Changes

Cohort / File(s) Summary
Helm chart metadata
helm/krr-enforcer/Chart.yaml
Updated version and appVersion from 0.3.1 to 0.3.4.
Certificate job template
helm/krr-enforcer/templates/enforcer-cert-job.yaml
Switched static image to {{ .Values.certJob.image }}; added conditional OpenSSL install controlled by Values.certJob.installOpenssl; certificate generation flow retained.
Values configuration
helm/krr-enforcer/values.yaml
Added certJob block with image: "alpine/k8s:1.30.0" and installOpenssl: true; updated image.tag to 0.3.4.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor User as Helm User
  participant Helm as Helm Template/Install
  participant K8s as Kubernetes
  participant Job as Cert Job Pod
  participant Script as Init Script

  User->>Helm: helm install/upgrade (values)
  Helm->>K8s: Rendered manifests (job uses .Values.certJob.image)
  K8s-->>User: Resources created
  K8s->>Job: Schedule Pod
  Job->>Script: Run init script

  alt installOpenssl == true
    Script->>Script: apk add --no-cache openssl
  else installOpenssl == false
    Note over Script: Skip OpenSSL installation
  end

  Script->>Script: Generate CA and server certs
  Script->>K8s: Create/Update Secret with certs
  Script-->>Job: Exit 0
  Job-->>K8s: Complete
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Title Check ✅ Passed The title describes swapping the kubectl image for an Alpine variant, which reflects part of the change, but it omits that the PR’s main purpose is to make the image configurable rather than hard-coded. It therefore only partially summarizes the primary change.
Description Check ✅ Passed The description clearly states that the PR allows overriding the kubectl image, which directly corresponds to the modifications in the Helm templates and values, making it relevant and on-topic.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch alpine-kubectl

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6e84f09 and 04deb1f.

📒 Files selected for processing (3)
  • helm/krr-enforcer/Chart.yaml (1 hunks)
  • helm/krr-enforcer/templates/enforcer-cert-job.yaml (2 hunks)
  • helm/krr-enforcer/values.yaml (1 hunks)

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.

@arikalon1 arikalon1 merged commit f5d9744 into main Oct 9, 2025
3 checks passed
@arikalon1 arikalon1 deleted the alpine-kubectl branch October 9, 2025 08:55
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