1
0
Fork 0
mirror of https://github.com/kyverno/policy-reporter.git synced 2024-12-14 11:57:32 +00:00

Implement CI for helm chart (#15)

* Implement CI for helm chart
* fixed typo in helm ci
* removed non-use pkg fron helm-chart CI

Co-authored-by: yuriydzobak <yurii.dzobak@lotusflare.com>
This commit is contained in:
Yurii Dzobak 2021-03-17 02:25:30 +02:00 committed by GitHub
parent 8c30dfdb17
commit cdf6686b29
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 125 additions and 1 deletions

37
.github/ct_chart_schema.yaml vendored Normal file
View file

@ -0,0 +1,37 @@
name: str()
home: str(required=False)
version: str()
type: str(required=False)
apiVersion: str()
appVersion: any(str(), num())
description: str()
keywords: list(str(), required=False)
sources: list(str(), required=False)
maintainers: list(include('maintainer'), required=False)
icon: str(required=False)
engine: str(required=False)
condition: str(required=False)
tags: str(required=False)
deprecated: bool(required=False)
kubeVersion: str(required=False)
annotations: map(str(), str(), required=False)
dependencies: list(include('dependency'), required=False)
---
maintainer:
name: str(required=False)
email: str(required=False)
url: str(required=False)
---
dependency:
name: str()
version: str()
repository: str(required=False)
condition: str(required=False)
tags: list(str(), required=False)
enabled: bool(required=False)
import-values: any(list(str()), list(include('import-value')), required=False)
alias: str(required=False)
---
import-value:
child: str()
parent: str()

42
.github/ct_lintconf.yaml vendored Normal file
View file

@ -0,0 +1,42 @@
---
rules:
braces:
min-spaces-inside: 0
max-spaces-inside: 0
min-spaces-inside-empty: -1
max-spaces-inside-empty: -1
brackets:
min-spaces-inside: 0
max-spaces-inside: 0
min-spaces-inside-empty: -1
max-spaces-inside-empty: -1
colons:
max-spaces-before: 0
max-spaces-after: 1
commas:
max-spaces-before: 0
min-spaces-after: 1
max-spaces-after: 1
comments:
require-starting-space: true
min-spaces-from-content: 1
document-end: disable
document-start: disable # No --- to start a file
empty-lines:
max: 2
max-start: 0
max-end: 1
hyphens:
max-spaces-after: 1
indentation:
spaces: consistent
indent-sequences: whatever # - list indentation will handle both indentation and without
check-multi-line-strings: false
key-duplicates: enable
line-length: disable # Lines can be any length
new-line-at-end-of-file: enable
new-lines:
type: unix
trailing-spaces: enable
truthy:
level: warning

32
.github/workflows/helm-chart.yaml vendored Normal file
View file

@ -0,0 +1,32 @@
name: Lint helm chart
on:
push:
# run pipeline on push on master
branches:
- main
- development
paths:
- "charts/**"
pull_request:
paths:
- "charts/**"
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: "0"
- name: chart-testing (ct lint)
uses: helm/chart-testing-action@v2.0.1
- name: Run Helm Chart lint
run: |
ct lint --lint-conf=.github/ct_lintconf.yaml \
--chart-yaml-schema=.github/ct_chart_schema.yaml \
--target-branch=main --validate-maintainers=false \
--chart-dirs charts

View file

@ -0,0 +1,9 @@
dependencies:
- name: monitoring
repository: ""
version: 0.3.0
- name: policy-reporter-ui
repository: ""
version: 0.3.1
digest: sha256:e97dcecd7cb9a7270e6a644513aebc689fd4ddd01f373af066e53183b7607baf
generated: "2021-03-17T01:40:03.488467+02:00"

View file

@ -5,11 +5,15 @@ description: |
It creates Prometheus Metrics and can send rule validation events to different targets like Loki, Elasticsearch, Slack or Discord
type: application
version: 0.17.0
version: 0.17.1
appVersion: 0.12.0
dependencies:
- name: monitoring
condition: monitoring.enabled
repository: ""
version: "0.3.0"
- name: policy-reporter-ui
condition: ui.enabled
repository: ""
version: "0.3.1"