Skip to content

Commit 7ececfd

Browse files
committed
Discrete helm charts for CA, VPA
1 parent 9befb31 commit 7ececfd

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+113
-51
lines changed
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
permissions:
2+
contents: read
3+
4+
jobs:
5+
ca-release:
6+
permissions:
7+
contents: write # for helm/chart-releaser-action to push chart release and create a release
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Checkout
11+
uses: actions/[email protected]
12+
with:
13+
fetch-depth: 0
14+
15+
- name: Configure Git
16+
run: |
17+
git config user.name "${GITHUB_ACTOR}"
18+
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
19+
20+
- name: Install Helm
21+
uses: azure/[email protected]
22+
with:
23+
version: v3.4.0
24+
25+
- env:
26+
CR_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27+
CR_RELEASE_NAME_TEMPLATE: "cluster-autoscaler-chart-{{ .Version }}"
28+
name: Run chart-releaser
29+
uses: helm/[email protected]
30+
with:
31+
charts_dir: cluster-autoscaler/charts
32+
vpa-release:
33+
permissions:
34+
contents: write # for helm/chart-releaser-action to push chart release and create a release
35+
runs-on: ubuntu-latest
36+
steps:
37+
- name: Checkout
38+
uses: actions/[email protected]
39+
with:
40+
fetch-depth: 0
41+
42+
- name: Configure Git
43+
run: |
44+
git config user.name "${GITHUB_ACTOR}"
45+
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
46+
47+
- name: Install Helm
48+
uses: azure/[email protected]
49+
with:
50+
version: v3.4.0
51+
52+
- env:
53+
CR_TOKEN: ${{ secrets.GITHUB_TOKEN }}
54+
CR_RELEASE_NAME_TEMPLATE: "vertical-pod-autoscaler-chart-{{ .Version }}"
55+
name: Run chart-releaser
56+
uses: helm/[email protected]
57+
with:
58+
charts_dir: vertical-pod-autoscaler/charts
59+
name: Release Charts
60+
on:
61+
push:
62+
branches:
63+
- master

.github/workflows/pr.yaml

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,10 @@ jobs:
1717
with:
1818
filters: |
1919
charts:
20-
- 'charts/**/Chart.yaml'
21-
- 'charts/**/*'
20+
- 'cluster-autoscaler/charts/**/Chart.yaml'
21+
- 'cluster-autoscaler/charts/**/*'
22+
- 'vertical-pod-autoscaler/charts/**/Chart.yaml'
23+
- 'vertical-pod-autoscaler/charts/**/*'
2224
token: ${{ secrets.GITHUB_TOKEN }}
2325
helm-lint-test:
2426
if: ${{ needs.changes.outputs.charts == 'true' }}
@@ -34,12 +36,12 @@ jobs:
3436
- name: Set up chart-testing
3537
uses: helm/[email protected]
3638
- name: Run chart-testing (lint)
37-
run: ct lint --target-branch ${{ github.event.pull_request.base.ref }}
39+
run: ct lint --chart-dirs cluster-autoscaler/charts vertical-pod-autoscaler/charts --target-branch ${{ github.event.pull_request.base.ref }}
3840
# Only build a kind cluster if there are chart changes to test.
3941
- name: Run chart-testing (list-changed)
4042
id: list-changed
4143
run: |
42-
changed=$(ct list-changed --target-branch ${{ github.event.pull_request.base.ref }})
44+
changed=$(ct list-changed --chart-dirs cluster-autoscaler/charts vertical-pod-autoscaler/charts --target-branch ${{ github.event.pull_request.base.ref }})
4345
if [[ -n "$changed" ]]; then
4446
echo "changed=true" >> $GITHUB_OUTPUT
4547
fi
@@ -48,7 +50,7 @@ jobs:
4850
uses: helm/[email protected]
4951
- if: steps.list-changed.outputs.changed == 'true'
5052
name: Run chart-testing (install)
51-
run: ct install --target-branch ${{ github.event.pull_request.base.ref }}
53+
run: ct install --chart-dirs cluster-autoscaler/charts vertical-pod-autoscaler/charts --target-branch ${{ github.event.pull_request.base.ref }}
5254
helm-docs-validate:
5355
if: ${{ needs.changes.outputs.charts == 'true' }}
5456
name: Helm Docs
@@ -59,14 +61,9 @@ jobs:
5961
- name: Checkout
6062
uses: actions/[email protected]
6163
- name: Run helm-docs
62-
uses: docker://jnorwood/helm-docs:v1.14.2
63-
- name: Check for changes
64-
run: |
65-
if ! git diff --exit-code charts/*/README.md; then
66-
echo "ERROR: Helm chart README.md files are out of date"
67-
echo "Run from charts/: docker run --rm --volume \"\$(pwd):/helm-docs\" -u \$(id -u) jnorwood/helm-docs:v1.14.2"
68-
exit 1
69-
fi
64+
uses: losisin/helm-docs-github-action@v1
65+
with:
66+
fail-on-diff: true
7067

7168
name: Lint and Test Charts
7269
on: pull_request

.github/workflows/release.yaml

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

README.md

Lines changed: 4 additions & 2 deletions
File renamed without changes.
Lines changed: 34 additions & 0 deletions

0 commit comments

Comments
 (0)