mirror of
https://github.com/hashicorp/vagrant.git
synced 2026-02-05 06:46:21 +01:00
Readd vbox tests
This commit is contained in:
@@ -17,7 +17,6 @@ export PKT_VAGRANT_HOST_MEMORY="${VAGRANT_HOST_MEMORY:-10000}"
|
||||
export PKT_VAGRANT_CWD="test/vagrant-spec/"
|
||||
export PKT_VAGRANT_VAGRANTFILE=Vagrantfile.spec
|
||||
export PKT_VAGRANT_SPEC_PROVIDERS="${VAGRANT_SPEC_PROVIDERS}"
|
||||
export PKT_VAGRANT_DOCKER_IMAGES="${VAGRANT_DOCKER_IMAGES}"
|
||||
###
|
||||
|
||||
# Grab vagrant-spec gem and place inside root dir of Vagrant repo
|
||||
|
||||
18
.github/workflows/spectesting.yml
vendored
18
.github/workflows/spectesting.yml
vendored
@@ -25,21 +25,20 @@ jobs:
|
||||
strategy:
|
||||
matrix:
|
||||
host_os: ['hashicorp/bionic64']
|
||||
guest_os: ['']
|
||||
docker_images: ['nginx']
|
||||
guest_os: ['hashicorp-vagrant/ubuntu-16.04']
|
||||
providers: ['docker', 'virtualbox']
|
||||
steps:
|
||||
- name: Code Checkout
|
||||
uses: actions/checkout@v1
|
||||
- name: Create packet host for tests
|
||||
- name: Create packet host for tests (provider ${{ matrix.providers }})
|
||||
run: ./.ci/spec/create-hosts.sh
|
||||
working-directory: ${{github.workspace}}
|
||||
env:
|
||||
VAGRANT_HOST_BOXES: ${{matrix.host_os}}
|
||||
VAGRANT_GUEST_BOXES: ${{matrix.guest_os}}
|
||||
VAGRANT_PRERELEASE_VERSION: ${{ github.event.client_payload.prerelease_version }}
|
||||
VAGRANT_SPEC_PROVIDERS: 'docker'
|
||||
VAGRANT_DOCKER_IMAGES: ${{matrix.docker_images}}
|
||||
|
||||
VAGRANT_SPEC_PROVIDERS: ${{matrix.providers}}
|
||||
|
||||
spec-tests:
|
||||
if: github.repository == 'hashicorp/vagrant-blackbox'
|
||||
runs-on: self-hosted
|
||||
@@ -48,16 +47,17 @@ jobs:
|
||||
strategy:
|
||||
matrix:
|
||||
host_os: ['hashicorp/bionic64']
|
||||
guest_os: ['']
|
||||
guest_os: ['hashicorp-vagrant/ubuntu-16.04']
|
||||
docker_images: ['nginx']
|
||||
providers: ['docker', 'virtualbox']
|
||||
steps:
|
||||
- name: Run Tests with host ${{ matrix.host_os }} using guest ${{ matrix.guest_os }}
|
||||
- name: Run Tests with host ${{ matrix.host_os }} using provider ${{ matrix.providers }}
|
||||
run: ./.ci/spec/run-test.sh
|
||||
working-directory: ${{github.workspace}}
|
||||
env:
|
||||
VAGRANT_HOST_BOXES: ${{matrix.host_os}}
|
||||
VAGRANT_GUEST_BOXES: ${{matrix.guest_os}}
|
||||
VAGRANT_SPEC_PROVIDERS: 'docker'
|
||||
VAGRANT_SPEC_PROVIDERS: ${{matrix.providers}}
|
||||
VAGRANT_DOCKER_IMAGES: ${{matrix.docker_images}}
|
||||
|
||||
cleanup:
|
||||
|
||||
@@ -4,10 +4,10 @@
|
||||
# Guest boxes to use for vagrant-spec
|
||||
GUEST_BOXES = {
|
||||
'hashicorp/bionic64' => '1.0.282',
|
||||
# 'hashicorp-vagrant/ubuntu-16.04' => '1.0.1',
|
||||
# 'hashicorp-vagrant/centos-7.4' => '1.0.2',
|
||||
# 'hashicorp-vagrant/windows-10' => '1.0.0',
|
||||
# 'spox/osx-10.12' => '0.0.1'
|
||||
'hashicorp-vagrant/ubuntu-16.04' => '1.0.1',
|
||||
'hashicorp-vagrant/centos-7.4' => '1.0.2',
|
||||
'hashicorp-vagrant/windows-10' => '1.0.0',
|
||||
'spox/osx-10.12' => '0.0.1'
|
||||
}
|
||||
|
||||
DOCKER_IMAGES = {
|
||||
@@ -17,10 +17,10 @@ DOCKER_IMAGES = {
|
||||
# Host boxes to run vagrant-spec
|
||||
HOST_BOXES = {
|
||||
'hashicorp/bionic64' => '1.0.282',
|
||||
# 'hashicorp-vagrant/ubuntu-16.04' => '1.0.1',
|
||||
# 'hashicorp-vagrant/centos-7.4' => '1.0.2',
|
||||
# 'hashicorp-vagrant/windows-10' => '1.0.0',
|
||||
# 'spox/osx-10.12' => '0.0.1'
|
||||
'hashicorp-vagrant/ubuntu-16.04' => '1.0.1',
|
||||
'hashicorp-vagrant/centos-7.4' => '1.0.2',
|
||||
'hashicorp-vagrant/windows-10' => '1.0.0',
|
||||
'spox/osx-10.12' => '0.0.1'
|
||||
}
|
||||
|
||||
# Not all boxes are named by their specific "platform"
|
||||
@@ -28,8 +28,8 @@ HOST_BOXES = {
|
||||
PLATFORM_SCRIPT_MAPPING = {
|
||||
"ubuntu" => "ubuntu",
|
||||
"bionic" => "ubuntu",
|
||||
# "centos" => "centos",
|
||||
# "windows" => "windows"
|
||||
"centos" => "centos",
|
||||
"windows" => "windows"
|
||||
}
|
||||
|
||||
# Determine what providers to test
|
||||
@@ -73,7 +73,6 @@ end
|
||||
Vagrant.configure(2) do |global_config|
|
||||
host_boxes.each do |box_name, box_version|
|
||||
platform = box_name.split('/').last.sub(/[^a-z]+$/, '')
|
||||
|
||||
enabled_providers.each do |provider_name|
|
||||
global_config.vm.define("#{box_name.split('/').last}-#{provider_name}") do |config|
|
||||
config.vm.box = box_name
|
||||
@@ -105,7 +104,7 @@ Vagrant.configure(2) do |global_config|
|
||||
path: "./scripts/#{platform}-run.#{provider_name}.ps1",
|
||||
keep_color: true,
|
||||
env: {
|
||||
"VAGRANT_SPEC_ARGS" => "--no-builtin #{spec_cmd_args}".strip,
|
||||
"VAGRANT_SPEC_ARGS" => "--no-builtin --component provider/docker/docker/* #{spec_cmd_args}".strip,
|
||||
"VAGRANT_SPEC_DOCKER_IMAGE" => docker_image
|
||||
}
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user