Skip to content

Commit 9843b33

Browse files
committed
feat(drupalwxt): Switch to chart releaser
1 parent 175aa05 commit 9843b33

File tree

9 files changed

+115
-260
lines changed

9 files changed

+115
-260
lines changed

.github/workflows/ci.yml

Lines changed: 0 additions & 16 deletions
This file was deleted.

.github/workflows/publish.yml

Lines changed: 0 additions & 47 deletions
This file was deleted.

.github/workflows/release.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Release Charts
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
release:
10+
# depending on default permission settings for your org (contents being read-only or read-write for workloads), you will have to add permissions
11+
# see: https://docs.github.com/en/actions/security-guides/automatic-token-authentication#modifying-the-permissions-for-the-github_token
12+
permissions:
13+
contents: write
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v2
18+
with:
19+
fetch-depth: 0
20+
21+
- name: Helm linting
22+
run: |
23+
./test/lint.sh
24+
25+
- name: Configure Git
26+
run: |
27+
git config user.name "chart-releaser"
28+
git config user.email "chart-releaser@users.noreply.github.com"
29+
30+
- name: Install Helm
31+
uses: azure/setup-helm@v1
32+
with:
33+
version: v3.8.1
34+
35+
- name: Add repositories
36+
run: |
37+
for repo in $(yq '.chart-repos[]' test/config.yaml); do helm repo add $(echo $repo | cut -d'=' -f1) $(echo $repo | cut -d'=' -f2) --force-update; done
38+
39+
- name: Run chart-releaser
40+
uses: helm/chart-releaser-action@v1.4.0
41+
with:
42+
charts_dir: .
43+
env:
44+
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
45+
CR_SKIP_EXISTING: 'true'

.github/workflows/test.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Test Helm Charts
2+
on:
3+
pull_request:
4+
branches:
5+
- master
6+
7+
jobs:
8+
test:
9+
name: 'Test'
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v2
15+
16+
- name: Helm linting
17+
run: |
18+
./test/lint.sh

docs/kind.yaml

Lines changed: 0 additions & 10 deletions
This file was deleted.

docs/local-dev-kind.md

Lines changed: 0 additions & 185 deletions
This file was deleted.

test/config.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ chart-repos:
55
- bitnami=https://charts.bitnami.com/bitnami
66
- helm=https://charts.helm.sh/stable
77
- statcan=https://statcan.github.io/charts
8-
- minio=https://helm.min.io/
98
check-version-increment: true
109
validate-maintainers: false
1110
excluded-charts:

test/lint.sh

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,16 @@
22

33
set -euxo pipefail
44

5+
CHARTS="$@"
6+
CHART_TESTING_VERSION="3.7.0"
7+
8+
if [ -z "$CHARTS" ]; then
9+
CHARTS="--all"
10+
else
11+
CHARTS="--charts $CHARTS"
12+
fi
13+
514
docker run --rm \
615
--volume "$(pwd):/workdir" \
716
--workdir /workdir \
8-
"quay.io/helmpack/chart-testing:v3.1.1" ct lint --config test/config.yaml --all
17+
"quay.io/helmpack/chart-testing:v${CHART_TESTING_VERSION}" ct lint --config test/config.yaml --lint-conf test/lintconf.yaml $CHARTS

test/lintconf.yaml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
---
2+
rules:
3+
braces:
4+
min-spaces-inside: 0
5+
max-spaces-inside: 0
6+
min-spaces-inside-empty: -1
7+
max-spaces-inside-empty: -1
8+
brackets:
9+
min-spaces-inside: 0
10+
max-spaces-inside: 0
11+
min-spaces-inside-empty: -1
12+
max-spaces-inside-empty: -1
13+
colons:
14+
max-spaces-before: 0
15+
max-spaces-after: 1
16+
commas:
17+
max-spaces-before: 0
18+
min-spaces-after: 1
19+
max-spaces-after: 1
20+
comments:
21+
require-starting-space: false
22+
min-spaces-from-content: 1
23+
document-end: disable
24+
document-start: disable # No --- to start a file
25+
empty-lines:
26+
max: 2
27+
max-start: 0
28+
max-end: 0
29+
hyphens:
30+
max-spaces-after: 1
31+
indentation:
32+
spaces: consistent
33+
indent-sequences: whatever # - list indentation will handle both indentation and without
34+
check-multi-line-strings: false
35+
key-duplicates: enable
36+
line-length: disable # Lines can be any length
37+
new-line-at-end-of-file: enable
38+
new-lines:
39+
type: unix
40+
trailing-spaces: enable
41+
truthy:
42+
level: warning

0 commit comments

Comments
 (0)