Skip to content

Commit

Permalink
fix: release helm chart failing due to invalid token (#209)
Browse files Browse the repository at this point in the history
* - Adding repositories for which token is needed

* - Addressing error "A sequence was not expected"

* - Restored the trigger on v*

* - Tempalized the clusterrole to get the correct labels

* - trigger

* - Correcting the label

* - Adding k8tls adpater as a dependency
  • Loading branch information
shivaccuknox authored Jul 3, 2024
1 parent 4409c45 commit 7f7a00e
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 3 deletions.
1 change: 1 addition & 0 deletions .github/workflows/stable-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ jobs:
with:
app-id: ${{ vars.ACTIONS_APP_ID }}
private-key: ${{ secrets.ACTIONS_APP_PRIVATE_KEY }}
repositories: charts

- name: Publish Helm chart
uses: stefanprodan/helm-gh-pages@master
Expand Down
9 changes: 9 additions & 0 deletions deployments/nimbus-kyverno/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,15 @@ app.kubernetes.io/name: {{ include "nimbus-kyverno.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
ClusterRoleSelector labels
*/}}
{{- define "nimbus-kyverno.clusterRoleSelectorLabels" -}}
app.kubernetes.io/component: background-controller
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/part-of: {{ .Release.Name }}-kyverno
{{- end }}

{{/*
Create the name of the service account to use
*/}}
Expand Down
4 changes: 1 addition & 3 deletions deployments/nimbus-kyverno/templates/clusterrole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
labels:
app.kubernetes.io/component: background-controller
app.kubernetes.io/instance: nimbus-kyverno
app.kubernetes.io/part-of: nimbus-kyverno
{{- include "nimbus-kyverno.clusterRoleSelectorLabels" . | nindent 4 }}
name: nimbus-kyverno:update-resources
rules:
- apiGroups:
Expand Down
5 changes: 5 additions & 0 deletions deployments/nimbus/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,8 @@ dependencies:
version: ">= 0.1.0"
repository: https://5gsec.github.io/charts
condition: autoDeploy.kyverno

- name: nimbus-k8tls
version: ">= 0.1.0"
repository: https://5gsec.github.io/charts
condition: autoDeploy.k8tls
1 change: 1 addition & 0 deletions deployments/nimbus/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ autoDeploy:
kubearmor: true
netpol: true
kyverno: true
k8tls: true

replicaCount: 1

Expand Down

0 comments on commit 7f7a00e

Please sign in to comment.