Skip to content

Commit

Permalink
Add helm/chart-testing linting
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Farrell <dfarrell@redhat.com>
  • Loading branch information
dfarrell07 committed Jun 11, 2021
1 parent df9a462 commit d88107c
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 8 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,29 @@ on:
pull_request:

jobs:
chart-testing:
name: Helm Chart Linting
runs-on: ubuntu-latest
steps:
- name: Check out the repository
uses: actions/checkout@v2

- name: Set up Helm
uses: azure/setup-helm@v1
with:
version: v3.6.0

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'

- name: Set up helm/chart-testing
uses: helm/chart-testing-action@v2.1.0

- name: Run helm/chart-testing (lint)
run: ct lint --config ct.yaml

gitlint:
name: Commit Message(s)
runs-on: ubuntu-latest
Expand Down
6 changes: 6 additions & 0 deletions ct.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
charts:
- submariner-operator
- submariner-k8s-broker
# Tests that maintainer name is valid GitHub account, which isn't what we want
# See: https://github.com/helm/chart-testing/issues/192
validate-maintainers: false
8 changes: 5 additions & 3 deletions submariner-k8s-broker/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
---
name: submariner-k8s-broker
version: 0.6.0
apiVersion: v2
appVersion: 0.6.0
description: Submariner Kubernetes Broker
keywords:
home: https://submariner-io.github.io/
sources:
- https://submariner-io.github.io/submariner-charts/charts
- https://submariner-io.github.io/submariner-charts/charts
maintainers:
- name: Submariner Developers
email: submariner-dev@googlegroups.com
- name: Contributors to the Submariner project
email: submariner-dev@googlegroups.com
url: https://submariner.io/
8 changes: 4 additions & 4 deletions submariner-k8s-broker/templates/rbac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: {{ template "submariner-k8s-broker.fullname" . }}:client
name: {{ template "submariner-k8s-broker.fullname" . }}-cluster
labels:
heritage: {{ .Release.Service | quote }}
release: {{ .Release.Name | quote }}
Expand All @@ -25,13 +25,13 @@ rules:
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: {{ template "submariner-k8s-broker.fullname" . }}:client
name: {{ template "submariner-k8s-broker.fullname" . }}-cluster
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: {{ template "submariner-k8s-broker.fullname" . }}:client
name: {{ template "submariner-k8s-broker.fullname" . }}-cluster
subjects:
- kind: ServiceAccount
name: {{ template "submariner-k8s-broker.clientServiceAccountName" . }}
namespace: {{ .Release.Namespace }}
{{- end -}}
{{- end -}}
4 changes: 3 additions & 1 deletion submariner-operator/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
---
name: submariner-operator
version: 0.7.0
apiVersion: v2
appVersion: 0.7.0
description: Submariner enables direct networking between Pods and Services in different Kubernetes clusters
keywords:
home: https://submariner-io.github.io/
sources:
- https://submariner-io.github.io/submariner-charts/charts
maintainers:
- name: Submariner Developers
- name: Contributors to the Submariner project
email: submariner-dev@googlegroups.com
url: https://submariner.io/

0 comments on commit d88107c

Please sign in to comment.