Skip to content

chore: update Telegraf versions for v1.29.1 #945

chore: update Telegraf versions for v1.29.1

chore: update Telegraf versions for v1.29.1 #945

name: "helm-charts/test"
on: pull_request
jobs:
lint-test:
runs-on: ubuntu-latest
strategy:
matrix:
node_image_version:
- v1.21.1 # default used by helm/[email protected] (kubernetes-sigs/[email protected])
- v1.22.4
name: lint-test (k8s ${{ matrix.node_image_version }})
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Fetch history
run: git fetch --prune --unshallow
- name: Set up Helm
uses: azure/setup-helm@v1
with:
version: v3.6.3
- uses: actions/setup-python@v2
with:
python-version: 3.7
- name: Install chart-testing tools
id: lint
uses: helm/[email protected]
- name: Run chart-testing (list-changed)
id: list-changed
run: |
changed=$(ct list-changed)
if [[ -n "$changed" ]]; then
echo "::set-output name=changed::true"
fi
- name: Run chart-testing (lint)
run: ct lint
- name: Create kind cluster
uses: helm/[email protected]
with:
node_image: kindest/node:${{ matrix.node_image_version }}
if: steps.list-changed.outputs.changed == 'true'
# Our Enterprise chart requires some resources created
- name: Create Enterprise Test Resources
run: |
kubectl apply --validate=false -f https://github.com/jetstack/cert-manager/releases/download/v1.5.4/cert-manager.yaml
sleep 30 # wait for CertManager
kubectl apply -f ./charts/influxdb-enterprise/example-resources.yaml
kubectl create secret generic influxdb-license --from-literal=INFLUXDB_ENTERPRISE_LICENSE_KEY=${INFLUXDB_ENTERPRISE_LICENSE_KEY}
env:
INFLUXDB_ENTERPRISE_LICENSE_KEY: "${{ secrets.INFLUXDB_ENTERPRISE_LICENSE_KEY }}"
if: steps.list-changed.outputs.changed == 'true'
- name: Run chart-testing (install)
id: install
run: |
ct install --namespace=default 2>&1 | tee $RUNNER_TEMP/$GITHUB_RUN_NUMBER.txt
# When https://github.com/helm/chart-testing/issues/212 is fixed, this can be used to set the license key instead of using env from secret
# run: ct install --namespace=default --helm-extra-args="--set license.key=${INFLUXDB_ENTERPRISE_LICENSE_KEY}"
# env:
# INFLUXDB_ENTERPRISE_LICENSE_KEY: "${{ secrets.INFLUXDB_ENTERPRISE_LICENSE_KEY }}"
if: steps.list-changed.outputs.changed == 'true'
- name: Check logs for errors
run: |
set +e
patterns="Error loading config file"
grep -f $GITHUB_WORKSPACE/.github/workflows/patterns.txt $RUNNER_TEMP/$GITHUB_RUN_NUMBER.txt
if [[ $? -eq 0 ]]; then
echo "::error:: Errors found in logs"
exit 1
fi
if: steps.list-changed.outputs.changed == 'true'