Skip to content

Commit

Permalink
fix: Regression with secrets fullname (#127)
Browse files Browse the repository at this point in the history
* fix: Secrets fullname and add CI test for secrets

* fix: Release workflow badge URL
  • Loading branch information
brtkwr authored Dec 28, 2023
1 parent 3bbf47e commit 4f5c841
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 12 deletions.
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
# Unleash Kubernetes Helm Chart

[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0) ![Release Charts](https://github.com/unleash/helm-charts/workflows/release-chart/badge.svg?branch=main)
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
[![Release](https://github.com/Unleash/helm-charts/actions/workflows/release.yaml/badge.svg?branch=main)](https://github.com/Unleash/helm-charts/actions/workflows/release.yaml)

## Usage

[Helm](https://helm.sh) must be installed to use the charts.
Please refer to Helm's [documentation](https://helm.sh/docs/) to get started.

Once Helm is set up properly, add the repo as follows:
Once Helm is set up properly, add the repository as follows:

```console
helm repo add unleash https://docs.getunleash.io/helm-charts
Expand All @@ -22,8 +23,7 @@ You can then run `helm search repo unleash` to see the charts.

## Kubernetes support strategy

We'll build this repo on all k8s versions that have not reached End of Life according to the [Kubernetes support period](https://kubernetes.io/releases/patch-releases/#support-period).

We'll build this repository on all k8s versions that have not reached End of Life according to the [Kubernetes support period](https://kubernetes.io/releases/patch-releases/#support-period).

## Contributing

Expand All @@ -41,26 +41,26 @@ We'd love to have you contribute! Please refer to our [contribution guidelines](

## Helm charts build status

![Release Charts](https://github.com/unleash/helm-charts/workflows/release-chart/badge.svg?branch=main)
[![Release](https://github.com/Unleash/helm-charts/actions/workflows/release.yaml/badge.svg?branch=main)](https://github.com/Unleash/helm-charts/actions/workflows/release.yaml)

## Releasing the charts

To release new versions of the charts, you must update the chart version in the Chart.yaml file and then merge these modifications into the main branch. Following this, the workflow will detect these changes and automatically release a new version of the modified Helm chart.

## Helm repo
## Helm repository

This repository employs a process that converts it into a Helm repository, specifically using the Helm Chart Releaser Action version 1.5.0. It leverages GitHub Pages for hosting the artifacts. Furthermore, the Unleash documentation on Helm charts (found at https://docs.getunleash.io/helm-charts) utilizes a CNAME to direct to the GitHub Pages.
This repository employs a process that converts it into a Helm repository, specifically using the Helm Chart Releaser Action version 1.5.0. It leverages GitHub Pages for hosting the artifacts. Furthermore, the [Unleash documentation on Helm charts](https://docs.getunleash.io/helm-charts) utilizes a CNAME to direct to the GitHub Pages.

The specific workflow is outlined in the file located at .github/workflows/release.yml. This workflow activates whenever there's an update to the chart version, which consequently prompts an update to the repository with the new chart version.

## Testing the helm chart locally

To test the helm chart locally, first you should set up a local k8s environment. An easy way to do this is to set up kind, you can see instructions for setting it up [here](https://github.com/bricks-software/unleash-infra-docs/blob/main/commands/k8s.md).
To test the helm chart locally, first you should set up a local k8s environment. An easy way to do this is to set up kind, you can see instructions for setting it up [here](https://github.com/bricks-software/unleash-infra-docs/blob/main/commands/k8s.md).

Once you have your local k8s environment set up, you can run the following command to install the helm chart locally:

```
```bash
helm install --debug --generate-name . # this will install the chart using the local files provided you are in the folder that contains the chart
# To see the output of the helm chart without running it locally, you can run the following command:
helm install --debug --dry-run --generate-name .
```
```
2 changes: 1 addition & 1 deletion charts/unleash/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ sources:
- https://github.com/Unleash/unleash
- https://github.com/Unleash/helm-charts
type: application
version: 3.1.1
version: 3.1.2
3 changes: 3 additions & 0 deletions charts/unleash/ci/unleash-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,6 @@ autoscaling:
enabled: true
minReplicas: 1
maxReplicas: 4

secrets:
TEST_KEY: TEST_VALUE
2 changes: 1 addition & 1 deletion charts/unleash/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ spec:
- name: {{ $key }}
valueFrom:
secretKeyRef:
name: {{ include "unleash.fullname" . }}
name: {{ include "unleash.fullname" $ }}
key: {{ $key }}
{{- end }}
{{- end }}
Expand Down

0 comments on commit 4f5c841

Please sign in to comment.