mirror of
https://github.com/stefanprodan/podinfo.git
synced 2026-08-28 17:57:16 +00:00
Refactor Helm action
This commit is contained in:
@@ -1,10 +1,23 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
#!/usr/bin/env bash
|
||||
|
||||
HELM_V3=3.2.1
|
||||
BIN=/home/runner/bin
|
||||
curl -sSL https://get.helm.sh/helm-v${HELM_V3}-linux-amd64.tar.gz | tar xz
|
||||
mkdir -p ${BIN}
|
||||
cp linux-amd64/helm ${BIN}/helm
|
||||
rm -rf linux-amd64
|
||||
set -o errexit
|
||||
set -o nounset
|
||||
set -o pipefail
|
||||
|
||||
HELM_VERSION=3.2.1
|
||||
BIN_DIR=/home/runner/bin
|
||||
|
||||
main() {
|
||||
mkdir -p ${BIN_DIR}
|
||||
tmpDir=$(mktemp -d)
|
||||
|
||||
pushd $tmpDir >& /dev/null
|
||||
|
||||
curl -sSL https://get.helm.sh/helm-v${HELM_VERSION}-linux-amd64.tar.gz | tar xz
|
||||
cp linux-amd64/helm ${BIN_DIR}/helm
|
||||
|
||||
popd >& /dev/null
|
||||
rm -rf $tmpDir
|
||||
}
|
||||
|
||||
main
|
||||
@@ -20,7 +20,7 @@ jobs:
|
||||
restore-keys: |
|
||||
${{ runner.os }}-go-
|
||||
- name: Setup Go
|
||||
uses: actions/setup-go@v2-beta
|
||||
uses: actions/setup-go@v2
|
||||
with:
|
||||
go-version: 1.14.x
|
||||
- name: Setup Helm
|
||||
@@ -45,8 +45,7 @@ jobs:
|
||||
helm upgrade -i podinfo ./charts/podinfo \
|
||||
--set image.repository=test/podinfo \
|
||||
--set image.tag=latest \
|
||||
--namespace=default \
|
||||
--wait
|
||||
--namespace=default
|
||||
- name: Integration test
|
||||
run: |
|
||||
kubectl rollout status deployment/podinfo --timeout=1m
|
||||
|
||||
Reference in New Issue
Block a user