-
Notifications
You must be signed in to change notification settings - Fork 7
32 lines (24 loc) · 1.06 KB
/
e2e-test.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
name: 'e2e-test: install chart on kind'
on: pull_request
jobs:
test-install:
runs-on: ubuntu-24.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Create k8s Kind Cluster
uses: helm/[email protected]
- name: install chart
run: |
sed -i 's/\[\[ .Version \]\]/0.0.0/' helm/kube-prometheus-stack/Chart.yaml
helm dependency update ./helm/kube-prometheus-stack/
helm --kube-context kind-chart-testing install e2e-test-prometheus-operator ./helm/kube-prometheus-stack/ --wait
kubectl --context kind-chart-testing wait pod --for=condition=Ready -l app=kube-prometheus-stack-operator
sleep 120
STATE=$(kubectl --context kind-chart-testing get pods -l app=kube-prometheus-stack-operator -ojson | jq -r '.items | .[0].status.phase')
if [ "$STATE" == "Running" ]; then
echo 'prometheus operator is Running'
else
echo 'Error prometheus operator is not Running' >&2
exit 1
fi