Skip to content

issue 3: get docker release up and running #16

issue 3: get docker release up and running

issue 3: get docker release up and running #16

Workflow file for this run

name: Tests
on: [push, workflow_dispatch, pull_request]
env:
KIND_VERSION: "v0.19.0"
BATS_VERSION: "1.9.0"
NODE_VERSION: "19.8.1"
TARBALL_FILE: openbao-csi-provider.docker.tar
jobs:
copyright:
uses: hashicorp/vault-workflows-common/.github/workflows/copyright-headers.yaml@main
go-checks:
uses: hashicorp/vault-workflows-common/.github/workflows/go-checks.yaml@main
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
- uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1
with:
go-version-file: .go-version
- name: Install tools
run: make bootstrap
- name: Lint
run: make lint GOLANGCI_LINT_FORMAT=github-actions
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
- uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1
with:
go-version-file: .go-version
- name: Build
run: |
make e2e-image
docker save --output "${TARBALL_FILE}" e2e/openbao-csi-provider:latest
- name: Test
run: make test
- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2
with:
name: openbao-csi-provider-image
path: ${{ env.TARBALL_FILE }}
integration-test:
needs:
- lint
- test
strategy:
fail-fast: false
matrix:
kind-k8s-version: [1.27.13, 1.28.9, 1.29.4]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
- uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0
with:
node-version: ${{ env.NODE_VERSION }}
- run: npm install -g bats@${{ env.BATS_VERSION }}
shell: bash
- run: bats -v
shell: bash
- name: Create Kind Cluster
uses: helm/kind-action@fa81e57adff234b2908110485695db0f181f3c67 # v1.7.0
with:
cluster_name: kind
config: test/bats/configs/kind/config.yaml
node_image: kindest/node:v${{ matrix.kind-k8s-version }}
version: ${{ env.KIND_VERSION }}
- uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a # v3.0.2
with:
name: openbao-csi-provider-image
- name: Load openbao-csi-provider dev image
run: docker image load --input ${{ env.TARBALL_FILE }}
- name: bats tests
run: DISPLAY_SETUP_TEARDOWN_LOGS=true make e2e-setup e2e-test e2e-teardown