-
Notifications
You must be signed in to change notification settings - Fork 9
62 lines (54 loc) · 2.01 KB
/
release-update-metadata.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: Update metadata files for release
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
push:
branches:
- release-please--branches--main--components-*
jobs:
getChangedChart:
uses: ./.github/workflows/get-changed-chart.yaml
update-metadata-files:
runs-on: ubuntu-22.04
needs: getChangedChart
name: update metadata file for release
env:
CT_TARGET_BRANCH: ${{ github.event.repository.default_branch }}
CHART: ${{ needs.getChangedChart.outputs.chart }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.ACTIONS_BOT_TOKEN }}
- run: pip install yq
- name: Install sponge
run: sudo apt-get -yq install moreutils
- run: ./.github/scripts/prepare-values.sh "charts/$CHART"
- name: extract images
run: ./.github/scripts/extract-artifacthub-images.sh "charts/$CHART"
- name: enforce trusted registries
run: ./.github/scripts/enforce-trusted-registries.sh "charts/$CHART"
- name: Commit artifacthub images
uses: EndBug/add-and-commit@v9
with:
message: "chore: [bot] Update images in 'Chart.yaml'"
default_author: github_actions
push: false
add: charts/${{ needs.getChangedChart.outputs.chart }}/Chart.yaml
- run: pip install json-schema-for-humans
- name: generate values.md
run: |
set -ex
generate-schema-doc --config-file .github/json-schema-to-md.yaml "charts/$CHART/values.schema.json" "charts/$CHART/values.md"
- name: generate Docs
uses: docker://jnorwood/helm-docs:latest
with:
args: -g charts/${{ needs.getChangedChart.outputs.chart }}
- name: Commit README
uses: EndBug/add-and-commit@v9
with:
message: "chore: [bot] Update 'README.md'"
default_author: github_actions
push: true
add: charts/${{ needs.getChangedChart.outputs.chart }}/README.md