vaguerent/.github/workflows/spectesting.yml
Brian Cain f04137b05d
Only use hashicorp-vagrant box for now
The official bionic box does not have puppet installed, so the spec
tests will fail
2020-05-13 09:35:45 -07:00

59 lines
1.6 KiB
YAML

on:
push:
branches:
- 'spec-test-*'
paths-ignore:
- 'CHANGELOG.md'
- 'website/**'
jobs:
setup-packet:
if: github.repository == 'hashicorp/vagrant-blackbox'
runs-on: self-hosted
name: Build Packet Instance
steps:
- name: Create packet instance
run: .ci/spec/create-packet.sh
working-directory: ${{github.workspace}}
setup-hosts:
if: github.repository == 'hashicorp/vagrant-blackbox'
runs-on: self-hosted
name: Vagrant-Spec Start Hosts
needs: setup-packet
steps:
- name: Code Checkout
uses: actions/checkout@v1
- name: Run Tests with host ${{ matrix.host_os }} using guest ${{ matrix.guest_os }}
run: .ci/spec/create-hosts.sh
working-directory: ${{github.workspace}}
env:
VAGRANT_HOST_BOXES: hashicorp/bionic64
VAGRANT_GUEST_BOXES: hashicorp-vagrant/ubuntu-16.04
spec-tests:
if: github.repository == 'hashicorp/vagrant-blackbox'
runs-on: self-hosted
name: Vagrant-Spec Tests
needs: setup-hosts
steps:
- name: Run Tests with all hosts and guests
run: .ci/spec/run-test.sh
working-directory: ${{github.workspace}}
env:
VAGRANT_HOST_BOXES: hashicorp/bionic64
VAGRANT_GUEST_BOXES: hashicorp-vagrant/ubuntu-16.04
cleanup:
if: github.repository == 'hashicorp/vagrant-blackbox'
runs-on: self-hosted
name: Cleanup Post Vagrant-Spec Tests
needs: spec-tests
steps:
- name: Clean Packet
if: always()
run: .ci/spec/clean-packet.sh
- name: Clean Workspace
if: always()
run: rm -rf ${{ github.workspace }}