release v2.2.0 #471
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: | |
push: | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@8f4b7f84864484a7bf31766abe9204da3cbe65b3 # v3.5.0 | |
- name: Read Go version | |
id: go-version | |
run: echo "version=$(cat ./.go-version)" >> $GITHUB_OUTPUT | |
- name: Install Go | |
uses: actions/setup-go@4d34df0c2316fe8122ab82dc22947d607c0c91f9 # v4.0.0 | |
with: | |
go-version: ${{ steps.go-version.outputs.version }} | |
- name: Run go vet | |
run: make vet | |
- name: Install vault, nomad, consul | |
env: | |
NOMAD_LICENSE: ${{ secrets.NOMAD_LICENSE }} | |
run: | | |
./scripts/getnomad.sh | |
./scripts/getvault.sh | |
./scripts/getconsul.sh | |
- name: Start nomad | |
env: | |
NOMAD_LICENSE: ${{ secrets.NOMAD_LICENSE }} | |
run: ./scripts/start-nomad.sh | |
- name: Run acceptance tests | |
run: NOMAD_TOKEN=${{ env.NOMAD_TOKEN }} make testacc | |
env: | |
NOMAD_TOKEN: 00000000-0000-0000-0000-000000000000 | |
- name: Stop nomad | |
if: always() | |
run: ./scripts/stop-nomad.sh | |
- name: Make Nomad data dir and log file readable | |
if: always() | |
run: | | |
sudo chmod -R 777 /tmp/nomad | |
sudo chmod 666 /tmp/nomad.log | |
# - name: Upload logs | |
# uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2 | |
# if: always() | |
# with: | |
# name: logs | |
# path: | | |
# /tmp/consul.log | |
# /tmp/nomad.log | |
# /tmp/vault.log | |
# /tmp/nomad/data/**/alloc/logs/plugin* | |
# !/tmp/nomad/data/**/alloc/logs/*.fifo | |
# if-no-files-found: warn | |
# retention-days: 3 |