Chef 16 support
This adds support for testing both Chef/Cinc 15 and Chef/Cinc 16 which are still supported upstream. For now this disables voting on 16 as we have some known issues that need to be worked out first. In addition, this updates to Chef Workstation 20.8.111 which includes Chef 16 for spec testing. For now, let's only worry about doing unit testing against Chef 16 and worry about integration testing to catch any issues with Chef 15. Also remove installation of the fog-openstack gem as it's now included in Chef Workstation by default. Change-Id: I191b14a295bf323ab37f5a97298f9f0594e8843c Signed-off-by: Lance Albertson <lance@osuosl.org>
This commit is contained in:
parent
841565eb25
commit
0e1bbc88fc
66
.zuul.yaml
66
.zuul.yaml
|
@ -17,6 +17,7 @@
|
|||
run: playbooks/integration.yaml
|
||||
post-run: playbooks/post.yaml
|
||||
timeout: 5400
|
||||
voting: false # TODO(ramereth): Remove after this gets merged
|
||||
|
||||
- job:
|
||||
name: openstack-chef-minimal-integration-ubuntu
|
||||
|
@ -28,6 +29,13 @@
|
|||
run: playbooks/minimal.yaml
|
||||
post-run: playbooks/post.yaml
|
||||
timeout: 5400
|
||||
voting: false # TODO(ramereth): Remove after this gets merged
|
||||
|
||||
- job:
|
||||
name: openstack-chef15-minimal-integration-ubuntu
|
||||
parent: openstack-chef-minimal-integration-ubuntu
|
||||
vars:
|
||||
openstack_chef_client_version: 15
|
||||
|
||||
- job:
|
||||
name: openstack-chef-integration-centos
|
||||
|
@ -39,6 +47,7 @@
|
|||
run: playbooks/integration.yaml
|
||||
post-run: playbooks/post.yaml
|
||||
timeout: 5400
|
||||
voting: false # TODO(ramereth): Remove after this gets merged
|
||||
|
||||
- job:
|
||||
name: openstack-chef-minimal-integration-centos
|
||||
|
@ -50,6 +59,20 @@
|
|||
run: playbooks/minimal.yaml
|
||||
post-run: playbooks/post.yaml
|
||||
timeout: 5400
|
||||
voting: false # TODO(ramereth): Remove after this gets merged
|
||||
|
||||
- job:
|
||||
name: openstack-chef15-minimal-integration-centos
|
||||
parent: openstack-chef-minimal-integration-centos
|
||||
vars:
|
||||
openstack_chef_client_version: 15
|
||||
|
||||
- job:
|
||||
name: openstack-cinc15-integration-ubuntu
|
||||
parent: openstack-chef-integration-ubuntu
|
||||
vars:
|
||||
openstack_chef_client_type: cinc
|
||||
openstack_chef_client_version: 15
|
||||
|
||||
- job:
|
||||
name: openstack-cinc-integration-ubuntu
|
||||
|
@ -57,6 +80,13 @@
|
|||
vars:
|
||||
openstack_chef_client_type: cinc
|
||||
|
||||
- job:
|
||||
name: openstack-cinc15-integration-centos
|
||||
parent: openstack-chef-integration-centos
|
||||
vars:
|
||||
openstack_chef_client_type: cinc
|
||||
openstack_chef_client_version: 15
|
||||
|
||||
- job:
|
||||
name: openstack-cinc-integration-centos
|
||||
parent: openstack-chef-integration-centos
|
||||
|
@ -68,40 +98,52 @@
|
|||
check:
|
||||
jobs:
|
||||
- openstack-chef-delivery
|
||||
- openstack-chef-integration-ubuntu
|
||||
- openstack-chef-integration-centos
|
||||
- openstack-cinc-integration-ubuntu
|
||||
- openstack-chef-integration-ubuntu
|
||||
- openstack-cinc15-integration-centos
|
||||
- openstack-cinc15-integration-ubuntu
|
||||
- openstack-cinc-integration-centos
|
||||
- openstack-cinc-integration-ubuntu
|
||||
gate:
|
||||
queue: openstack-chef
|
||||
jobs:
|
||||
- openstack-chef-delivery
|
||||
- openstack-chef-integration-ubuntu
|
||||
- openstack-chef-integration-centos
|
||||
- openstack-cinc-integration-ubuntu
|
||||
- openstack-chef-integration-ubuntu
|
||||
- openstack-cinc15-integration-centos
|
||||
- openstack-cinc15-integration-ubuntu
|
||||
- openstack-cinc-integration-centos
|
||||
- openstack-cinc-integration-ubuntu
|
||||
|
||||
- project-template:
|
||||
name: openstack-chef-jobs
|
||||
check:
|
||||
jobs:
|
||||
- openstack-chef-delivery
|
||||
- openstack-chef-integration-ubuntu
|
||||
- openstack-chef-integration-centos
|
||||
- openstack-cinc-integration-ubuntu
|
||||
- openstack-cinc-integration-centos
|
||||
- openstack-chef-minimal-integration-ubuntu
|
||||
- openstack-chef-integration-ubuntu
|
||||
- openstack-chef-minimal-integration-centos
|
||||
- openstack-chef-minimal-integration-ubuntu
|
||||
- openstack-chef15-minimal-integration-centos
|
||||
- openstack-chef15-minimal-integration-ubuntu
|
||||
- openstack-cinc15-integration-centos
|
||||
- openstack-cinc15-integration-ubuntu
|
||||
- openstack-cinc-integration-centos
|
||||
- openstack-cinc-integration-ubuntu
|
||||
gate:
|
||||
queue: openstack-chef
|
||||
jobs:
|
||||
- openstack-chef-delivery
|
||||
- openstack-chef-integration-ubuntu
|
||||
- openstack-chef-integration-centos
|
||||
- openstack-cinc-integration-ubuntu
|
||||
- openstack-cinc-integration-centos
|
||||
- openstack-chef-minimal-integration-ubuntu
|
||||
- openstack-chef-integration-ubuntu
|
||||
- openstack-chef-minimal-integration-centos
|
||||
- openstack-chef-minimal-integration-ubuntu
|
||||
- openstack-chef15-minimal-integration-centos
|
||||
- openstack-chef15-minimal-integration-ubuntu
|
||||
- openstack-cinc15-integration-centos
|
||||
- openstack-cinc15-integration-ubuntu
|
||||
- openstack-cinc-integration-centos
|
||||
- openstack-cinc-integration-ubuntu
|
||||
|
||||
- project:
|
||||
templates:
|
||||
|
|
|
@ -30,7 +30,7 @@ Prerequisites
|
|||
-------------
|
||||
|
||||
- Chef 15 or higher
|
||||
- `Chef Workstation`_ 0.18.3 or later
|
||||
- `Chef Workstation`_ 20.8.111 or later
|
||||
- `Vagrant`_ 2.0 or later with `VirtualBox>`_ or some other provider
|
||||
|
||||
.. _Chef Workstation: https://downloads.chef.io/chef-workstation/
|
||||
|
|
|
@ -19,7 +19,7 @@ provisioner:
|
|||
# always_update_cookbooks: <%= !ENV['CI'] %>
|
||||
always_update_cookbooks: true
|
||||
product_name: chef
|
||||
product_version: 15
|
||||
product_version: 16
|
||||
deprecations_as_errors: true
|
||||
# Copy secret to /tmp/kitchen on test VM. Kitchen tries to gather secrets
|
||||
# before any recipes had a chance to run -> we cannot use a recipe to put the
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
- hosts: all
|
||||
vars:
|
||||
release: 0.18.3
|
||||
release: 20.8.111
|
||||
chef_workstation: chef-workstation_{{ release }}-1_amd64.deb
|
||||
tasks:
|
||||
- name: Fetch chef-workstation package
|
||||
|
@ -19,6 +19,3 @@
|
|||
- name: Show chef environment, accept chef license as side effect
|
||||
shell: chef env --chef-license accept
|
||||
become: yes
|
||||
- name: Install newer fog-openstack gem
|
||||
shell: chef gem install fog-openstack --version '~> 1.0.0' --no-user-install -N
|
||||
become: yes
|
||||
|
|
|
@ -1 +1,2 @@
|
|||
openstack_chef_client_type: chef
|
||||
openstack_chef_client_version: 16
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
- name: Install client
|
||||
script:
|
||||
cmd: "{{ openstack_chef_client_type }}-install.sh -v 15"
|
||||
cmd: "{{ openstack_chef_client_type }}-install.sh -v {{ openstack_chef_client_version }}"
|
||||
become: yes
|
||||
- name: Create symlink for cinc
|
||||
file:
|
||||
|
|
|
@ -56,7 +56,7 @@ describe command "#{openrc} openstack zone create --email dnsmaster@example.com
|
|||
its('exit_status') { should eq 0 }
|
||||
end
|
||||
|
||||
describe command "#{openrc} openstack recordset create --record '10.0.0.1' --type A example.com. www && sleep 10\"" do
|
||||
describe command "#{openrc} openstack recordset create --record '10.0.0.1' --type A example.com. www && sleep 20\"" do
|
||||
its('exit_status') { should eq 0 }
|
||||
end
|
||||
|
||||
|
|
|
@ -24,6 +24,8 @@ describe mysql_conf.params('mysqld') do
|
|||
its('max_connections') { should eq '307' }
|
||||
end
|
||||
|
||||
inspec_version = inspec.version
|
||||
|
||||
describe mysql_session('root', 'mypass', '127.0.0.1').query('show databases;') do
|
||||
%w(
|
||||
ceilometer
|
||||
|
@ -40,6 +42,12 @@ describe mysql_session('root', 'mypass', '127.0.0.1').query('show databases;') d
|
|||
nova_api
|
||||
nova_cell0
|
||||
).each do |db|
|
||||
its('stdout') { should include db }
|
||||
# TODO: Work around upstream InSpec issue
|
||||
# https://github.com/inspec/inspec/issues/5218
|
||||
if Gem::Version.new(inspec_version) >= Gem::Version.new('4.22.2')
|
||||
its('output') { should include db }
|
||||
else
|
||||
its('stdout') { should include db }
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue