commit af47ea6ef506385a98ac4c28115e2d7b71cefcce Author: Lance Albertson Date: Mon Oct 5 17:26:51 2020 -0700 Cookstyle 6.19.5 fixes Update ChefSpec due to changes made in apache2 cookbook. Depends-On: https://review.opendev.org/756168 Change-Id: I3ec792c519650b2d95a976ad50419a9b417a3514 Signed-off-by: Lance Albertson diff --git a/attributes/default.rb b/attributes/default.rb index e8a23c9..1f2c850 100644 --- a/attributes/default.rb +++ b/attributes/default.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 -# # Set to some text value if you want templated config files # to contain a custom banner at the top of the written file diff --git a/attributes/placement.rb b/attributes/placement.rb index 94390cd..ac7c196 100644 --- a/attributes/placement.rb +++ b/attributes/placement.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 -# # Set to some text value if you want templated config files # to contain a custom banner at the top of the written file diff --git a/recipes/_nova_apache.rb b/recipes/_nova_apache.rb index 99ab95e..d3282d2 100644 --- a/recipes/_nova_apache.rb +++ b/recipes/_nova_apache.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: _nova_apache diff --git a/recipes/_nova_cell.rb b/recipes/_nova_cell.rb index 01d3673..74f2bf9 100644 --- a/recipes/_nova_cell.rb +++ b/recipes/_nova_cell.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: _nova_cell diff --git a/recipes/api-metadata.rb b/recipes/api-metadata.rb index 5ce6d69..36311b6 100644 --- a/recipes/api-metadata.rb +++ b/recipes/api-metadata.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: api-metadata diff --git a/recipes/api-os-compute.rb b/recipes/api-os-compute.rb index 7565ce9..c3287b0 100644 --- a/recipes/api-os-compute.rb +++ b/recipes/api-os-compute.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: api-os-compute diff --git a/recipes/compute.rb b/recipes/compute.rb index 470ef36..a705b9b 100644 --- a/recipes/compute.rb +++ b/recipes/compute.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: compute diff --git a/recipes/conductor.rb b/recipes/conductor.rb index ff33c31..9d8dd46 100644 --- a/recipes/conductor.rb +++ b/recipes/conductor.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: nova # Recipe:: conductor diff --git a/recipes/identity_registration.rb b/recipes/identity_registration.rb index 2ecff0e..b4385e0 100644 --- a/recipes/identity_registration.rb +++ b/recipes/identity_registration.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: identity_registration diff --git a/recipes/libvirt.rb b/recipes/libvirt.rb index 1bb8787..6c55af4 100644 --- a/recipes/libvirt.rb +++ b/recipes/libvirt.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: libvirt diff --git a/recipes/nova-common.rb b/recipes/nova-common.rb index 7ac6fd1..8fb5eae 100644 --- a/recipes/nova-common.rb +++ b/recipes/nova-common.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: nova-common diff --git a/recipes/nova-setup.rb b/recipes/nova-setup.rb index 2d03d96..de58814 100644 --- a/recipes/nova-setup.rb +++ b/recipes/nova-setup.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: nova-setup diff --git a/recipes/placement_api.rb b/recipes/placement_api.rb index 3558d14..40ce3d1 100644 --- a/recipes/placement_api.rb +++ b/recipes/placement_api.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: placement-api diff --git a/recipes/scheduler.rb b/recipes/scheduler.rb index 6d3c222..abdcb42 100644 --- a/recipes/scheduler.rb +++ b/recipes/scheduler.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: scheduler diff --git a/recipes/serialproxy.rb b/recipes/serialproxy.rb index c1d4354..0347ba7 100644 --- a/recipes/serialproxy.rb +++ b/recipes/serialproxy.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: serialproxy diff --git a/recipes/vncproxy.rb b/recipes/vncproxy.rb index 7b60d17..ad4f646 100644 --- a/recipes/vncproxy.rb +++ b/recipes/vncproxy.rb @@ -1,4 +1,3 @@ -# encoding: UTF-8 # # Cookbook:: openstack-compute # Recipe:: vncproxy diff --git a/spec/_nova_apache_spec.rb b/spec/_nova_apache_spec.rb index c9e48cf..78cf655 100644 --- a/spec/_nova_apache_spec.rb +++ b/spec/_nova_apache_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::_nova_apache' do diff --git a/spec/_nova_cell_spec.rb b/spec/_nova_cell_spec.rb index 63bead6..6e0680b 100644 --- a/spec/_nova_cell_spec.rb +++ b/spec/_nova_cell_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::_nova_cell' do diff --git a/spec/api-metadata-redhat_spec.rb b/spec/api-metadata-redhat_spec.rb index 29e2a67..6169474 100644 --- a/spec/api-metadata-redhat_spec.rb +++ b/spec/api-metadata-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::api-metadata' do diff --git a/spec/api-metadata_spec.rb b/spec/api-metadata_spec.rb index 6df1581..b07fd0e 100644 --- a/spec/api-metadata_spec.rb +++ b/spec/api-metadata_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::api-metadata' do @@ -50,7 +48,7 @@ describe 'openstack-compute::api-metadata' do log_dir: '/var/log/apache2', processes: 2, protocol: '', - run_dir: '/var/lock/apache2', + run_dir: '/var/lock', server_entry: '/usr/bin/nova-metadata-wsgi', server_host: '127.0.0.1', server_port: '8775', @@ -68,7 +66,7 @@ describe 'openstack-compute::api-metadata' do /WSGIApplicationGroup %{GLOBAL}$/, %r{ErrorLog /var/log/apache2/nova-metadata_error.log$}, %r{CustomLog /var/log/apache2/nova-metadata_access.log combined$}, - %r{WSGISocketPrefix /var/lock/apache2$}, + %r{WSGISocketPrefix /var/lock$}, ].each do |line| it do expect(chef_run).to render_file('/etc/apache2/sites-available/nova-metadata.conf').with_content(line) diff --git a/spec/api-os-compute-redhat_spec.rb b/spec/api-os-compute-redhat_spec.rb index 2db8801..ecef456 100644 --- a/spec/api-os-compute-redhat_spec.rb +++ b/spec/api-os-compute-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::api-os-compute' do diff --git a/spec/api-os-compute_spec.rb b/spec/api-os-compute_spec.rb index 0b8625d..a94719f 100644 --- a/spec/api-os-compute_spec.rb +++ b/spec/api-os-compute_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::api-os-compute' do @@ -59,7 +57,7 @@ describe 'openstack-compute::api-os-compute' do log_dir: '/var/log/apache2', processes: 6, protocol: '', - run_dir: '/var/lock/apache2', + run_dir: '/var/lock', server_entry: '/usr/bin/nova-api-wsgi', server_host: '127.0.0.1', server_port: '8774', @@ -77,7 +75,7 @@ describe 'openstack-compute::api-os-compute' do /WSGIApplicationGroup %{GLOBAL}$/, %r{ErrorLog /var/log/apache2/nova-api_error.log$}, %r{CustomLog /var/log/apache2/nova-api_access.log combined$}, - %r{WSGISocketPrefix /var/lock/apache2$}, + %r{WSGISocketPrefix /var/lock$}, ].each do |line| it do expect(chef_run).to render_file('/etc/apache2/sites-available/nova-api.conf').with_content(line) diff --git a/spec/compute-redhat_spec.rb b/spec/compute-redhat_spec.rb index 7d7a655..87b4060 100644 --- a/spec/compute-redhat_spec.rb +++ b/spec/compute-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::compute' do diff --git a/spec/compute_spec.rb b/spec/compute_spec.rb index f752119..0e1ac83 100644 --- a/spec/compute_spec.rb +++ b/spec/compute_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::compute' do diff --git a/spec/conductor_redhat_spec.rb b/spec/conductor_redhat_spec.rb index eb58676..8cff332 100644 --- a/spec/conductor_redhat_spec.rb +++ b/spec/conductor_redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::conductor' do diff --git a/spec/conductor_spec.rb b/spec/conductor_spec.rb index 71a15af..a130e84 100644 --- a/spec/conductor_spec.rb +++ b/spec/conductor_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::conductor' do diff --git a/spec/identity_registration_spec.rb b/spec/identity_registration_spec.rb index 5348e4e..b699b29 100644 --- a/spec/identity_registration_spec.rb +++ b/spec/identity_registration_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::identity_registration' do diff --git a/spec/libvirt-redhat_spec.rb b/spec/libvirt-redhat_spec.rb index b799bf7..5e2091b 100644 --- a/spec/libvirt-redhat_spec.rb +++ b/spec/libvirt-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::libvirt' do diff --git a/spec/libvirt_spec.rb b/spec/libvirt_spec.rb index f0baa39..59b3274 100644 --- a/spec/libvirt_spec.rb +++ b/spec/libvirt_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::libvirt' do diff --git a/spec/nova-common-redhat_spec.rb b/spec/nova-common-redhat_spec.rb index d823c60..7183a11 100644 --- a/spec/nova-common-redhat_spec.rb +++ b/spec/nova-common-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::nova-common' do diff --git a/spec/nova-common_spec.rb b/spec/nova-common_spec.rb index 2ff41f9..a36caca 100644 --- a/spec/nova-common_spec.rb +++ b/spec/nova-common_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::nova-common' do diff --git a/spec/nova-setup_spec.rb b/spec/nova-setup_spec.rb index dd3aa9c..eb9fa24 100644 --- a/spec/nova-setup_spec.rb +++ b/spec/nova-setup_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::nova-setup' do diff --git a/spec/placement_api-redhat_spec.rb b/spec/placement_api-redhat_spec.rb index 3c2b087..aa71c42 100644 --- a/spec/placement_api-redhat_spec.rb +++ b/spec/placement_api-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::placement_api' do diff --git a/spec/placement_api_spec.rb b/spec/placement_api_spec.rb index 8368d3a..5aa58e7 100644 --- a/spec/placement_api_spec.rb +++ b/spec/placement_api_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::placement_api' do @@ -110,7 +108,7 @@ describe 'openstack-compute::placement_api' do log_dir: '/var/log/apache2', processes: 2, protocol: '', - run_dir: '/var/lock/apache2', + run_dir: '/var/lock', server_entry: '/usr/bin/placement-api', server_host: '127.0.0.1', server_port: '8778', @@ -128,7 +126,7 @@ describe 'openstack-compute::placement_api' do /WSGIApplicationGroup %{GLOBAL}$/, %r{ErrorLog /var/log/apache2/placement-api_error.log$}, %r{CustomLog /var/log/apache2/placement-api_access.log combined$}, - %r{WSGISocketPrefix /var/lock/apache2$}, + %r{WSGISocketPrefix /var/lock$}, ].each do |line| it do expect(chef_run).to render_file('/etc/apache2/sites-available/placement.conf').with_content(line) diff --git a/spec/scheduler-redhat_spec.rb b/spec/scheduler-redhat_spec.rb index 7286225..d0a41d9 100644 --- a/spec/scheduler-redhat_spec.rb +++ b/spec/scheduler-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::scheduler' do diff --git a/spec/scheduler_spec.rb b/spec/scheduler_spec.rb index 5cbc33f..d61ec7f 100644 --- a/spec/scheduler_spec.rb +++ b/spec/scheduler_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::scheduler' do diff --git a/spec/serialproxy-redhat_spec.rb b/spec/serialproxy-redhat_spec.rb index 1a06c00..9cc90e6 100644 --- a/spec/serialproxy-redhat_spec.rb +++ b/spec/serialproxy-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::serialproxy' do diff --git a/spec/serialproxy_spec.rb b/spec/serialproxy_spec.rb index 34e8bfa..1257a4e 100644 --- a/spec/serialproxy_spec.rb +++ b/spec/serialproxy_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::serialproxy' do diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 11d31c9..710e041 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require 'chefspec' require 'chefspec/berkshelf' require 'chef/application' diff --git a/spec/vncproxy-redhat_spec.rb b/spec/vncproxy-redhat_spec.rb index 03e874e..47b2089 100644 --- a/spec/vncproxy-redhat_spec.rb +++ b/spec/vncproxy-redhat_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::vncproxy' do diff --git a/spec/vncproxy_spec.rb b/spec/vncproxy_spec.rb index 033ec8f..8373480 100644 --- a/spec/vncproxy_spec.rb +++ b/spec/vncproxy_spec.rb @@ -1,5 +1,3 @@ -# encoding: UTF-8 - require_relative 'spec_helper' describe 'openstack-compute::vncproxy' do