-
Notifications
You must be signed in to change notification settings - Fork 22
102 lines (84 loc) · 2.96 KB
/
update-addons.yml
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
name: Update addons
on:
# Allow manual executions
workflow_dispatch:
# Run nightly
schedule:
- cron: '0 0 * * *'
jobs:
propose_update_pr:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- key: calico
path: cni.calico.chart
- key: cilium
path: cni.cilium.chart
- key: openstack-ccm
path: openstack.ccm.chart
- key: csi-cinder
path: openstack.csiCinder.chart
- key: metrics-server
path: metricsServer.chart
- key: kubernetes-dashboard
path: kubernetesDashboard.chart
- key: ingress-nginx
path: ingress.nginx.chart
- key: kube-prometheus-stack
path: monitoring.kubePrometheusStack.chart
- key: loki-stack
path: monitoring.lokiStack.chart
- key: node-feature-discovery
path: nodeFeatureDiscovery.chart
- key: nvidia-gpu-operator
path: nvidiaGPUOperator.chart
- key: mellanox-network-operator
path: mellanoxNetworkOperator.chart
name: ${{ matrix.key }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Extract repo and chart from values.yaml
id: chart-info
uses: stackhpc/github-actions/config-extract@master
with:
path: ./charts/cluster-addons/values.yaml
outputs: |
repo=${{ matrix.path }}.repo
name=${{ matrix.path }}.name
- name: Check for updates
id: next
uses: stackhpc/github-actions/helm-latest-version@master
with:
repository: ${{ steps.chart-info.outputs.repo }}
chart: ${{ steps.chart-info.outputs.name }}
- name: Update chart version in values.yaml
uses: stackhpc/github-actions/config-update@master
with:
path: ./charts/cluster-addons/values.yaml
updates: |
${{ matrix.path }}.version=${{ steps.next.outputs.version }}
- name: Generate app token for PR
uses: stackhpc/github-actions/generate-app-token@master
id: generate-app-token
with:
repository: ${{ github.repository }}
app-id: ${{ secrets.APP_ID }}
app-private-key: ${{ secrets.APP_PRIVATE_KEY }}
- name: Propose changes via PR if required
uses: peter-evans/create-pull-request@v5
with:
token: ${{ steps.generate-app-token.outputs.token }}
commit-message: >-
Update ${{ matrix.key }} addon to ${{ steps.next.outputs.version }}
branch: update-addon/${{ matrix.key }}
delete-branch: true
title: >-
Update ${{ matrix.key }} addon to ${{ steps.next.outputs.version }}
body: >
This PR was created automatically to update the
${{ matrix.key }} addon to ${{ steps.next.outputs.version }}.
labels: |
automation
addon-update