Update ChefSpec due to changes made in apache2 cookbook.
Depends-On: https://review.opendev.org/756168
Change-Id: Ie849f5bae082e94581146793f964d0e001a7c8c8
Signed-off-by: Lance Albertson <lance@osuosl.org>
- Cookstyle fixes
- Refactor Berksfile to use groups so we can exclude integration testing
cookbooks
- Update documentation
- Enable sensitive resources for the template[/etc/cinder/cinder.conf]
and to resources improve security.
- Update delivery configuration to exclude integration cookbooks
- Fix ChefSpec output.
- Switch package installations to send packages as arrays instead of individual
package resources. This generally speeds up chef runs.
Depends-On: https://review.opendev.org/701027
Depends-On: https://review.opendev.org/706151
Depends-On: https://review.opendev.org/706157
Change-Id: I73948a67e798477cfe7d3cf62474d0ea96f90db2
This brings us up to date with the latest apache2 cookbook which
included a major refactor in 6.0.0 removing all of the definitions and
recipe with proper resources. Instead of using the apache2_default_site
resource, directly use a template and then enable the config file using
the apache2_site resource. This gives us the most flexibility.
Other changes:
- Remove selinux for depends as it's not being referenced anywhere in
the cookbook
- Included more ChefSpec tests for api recipe
- Update WSGI template
- Include additional cookbooks in Berksfile required for CI
Depends-On: https://review.opendev.org/702772
Depends-On: https://review.opendev.org/701824
Change-Id: I289091f54750dd5068e98fd4f4853880f4b72c6c
This updates all references of let(:chef_run) to cached(:chef_run) to
speed up tests. By doing this, we have to create a new cached(:chef_run)
block whenever we need to adjust node attributes for testing.
- Remove unused default recipe ChefSpec
- Formatting cleanup
Speed was improved from 3 minutes 9.1 seconds to 38.21 seconds
Change-Id: I470991c600bca0ad2b6a389923a2fe8c954b7008
Python2.7 is going EOL soon, let us deploy python3 for Rocky from the
start, so we avoid having to switch later.
Clean up some unused pkg attributes.
Depends-On: https://review.opendev.org/682918
Change-Id: I1a11352f54b4126d7b510aa74d9ed1c4a33348c1
This uses edit_resource to add a notification in the block storage
apache configuration when it gets updated. This is a workaround due to
the fact we are using a version of the apache2 cookbook that is still
using definitions and cannot add notifications with definitions.
This will be removed in the Stein release when we migrate to the newer
apache2 cookbook which uses proper resources.
Change-Id: I7efddef83333ca0794ee3c298ca1a2488defe941
Signed-off-by: Lance Albertson <lance@osuosl.org>
fog-openstack-1.x already appends "auth/tokens" so we no longer need to
do that.
Depends-On: https://review.opendev.org/666176
Change-Id: Id090b2f70bf2844ce73fc75a1fe4871d3465485d
Signed-off-by: Lance Albertson <lance@osuosl.org>
Also fixes wrong service type reference in for wsgi banner
Change-Id: I82c60b7c4efaa19459a3a0ab835eb4e48f8ee991
Signed-off-by: Manuel Torrinha <manuel.torrinha@tecnico.ulisboa.pt>
- since the target package ships the default conf we won't need this
anymore
- the cinder target.conf is shipped by the cinder package to the right
directory
- removed targets.conf.erb since this isn't used anymore
- removed obsolete specs
Change-Id: I9485cc65231b1da8b24efdb7e25551e4d4688d6a
- openstack rocky uses bionic as ubuntu platform
the package name changed since ubuntu xenial.
fixed it
Change-Id: I3607d10577ee3391c39027676151bd5ef03259b5
The Chef Style Guide[1] does not recommend using hyphens for
cookbook or resource names. To maintain consistency, we should follow
best practices.
[1]: https://docs.chef.io/ruby.html#use-of-hyphens
Depends-On: Ic2b6d8f1cdf719791faaebdbd7e29e789eb3f31c
Change-Id: Ib8c788f69e9545b2d7121199590e3795f2212c7f
- scsi-target-utils comes from EPEL. Now that EPEL is disabled, this is removed
in favor of targetcli from the base repo. This is also available for Ubuntu to
provide a consistent outcome.
Change-Id: Ibc146350ef2ddd1d19e35402cbf69e036a759f1d
Implements: blueprint modern-chef
- deprecated postgresql support
- dropped apt cookbook dependency
- deprecated node.foo.bar method access for node['foo']['bar'] bracket syntax
- implemented foodcritic and cookstyle corrections
- migrated cinder api to a Chef-managed config
- deprecated cinder-group-active service, as it is no longer needed and gets in
the way of functionality
- added lvm cookbook dependency for better pv/vg handling
Implements blueprint modern-chef
Change-Id: Id248c9267af6750c871487bc8b577aa2011a782a
This patch removes the openstack_user resource with :grant_domain
action. A user is always created within a specific domain; such a
membership cannot be tacked on later. This resource gave the user the
role intended for their project for the domain (i.e., for the Default
domain instead of for the service project).
We add the domain_name attribute that creates the cinder user in the
desired domain. Note that this change needs a sufficiently recent
openstackclient cookbook -- otherwise the domain_name attribute is
ignored (which does not matter as long as the cinder user is to be
created in the Default domain).
Change-Id: I3d3cad8f870f80b577ded04588c401c27c62fbc8
This patch removes the role_name when using openstack_user's :create
action (it gets ignored by the target method).
Note that the spec test would still pass if only the line in
identity_registration.rb (but not the test) were changed, because the
code that actually does grant the role to the resource is executed right
after user creation and before any tests check the resource for the
existence of the role_name attribute. In other words: if the argument
were required in a call but only supplied in another call, the spec
tests would not catch it. Something to watch out for.
Change-Id: I320d0e85287aa5d6368d5be323999f8d9e1c462f
- Changed the default linter to cookstyle
- cinder-group-active was missing a Provides header for the SysV init script
- Switched the qemu package to SCL for CentOS to get a newer release
- Normalized template banner comment
Change-Id: Iec59e0c8e3cb0b83db92a0a9f8db34a40953351f
- cinder-group-active is still SysV, but can and will start via systemd if
coaxed to do so.
- Style and lint fixes for newer chefdk
- Removed ancient Gemfile
- Rewrote metadata.rb for readability
Change-Id: I4c26aea78220eb20fc4e5e964af93414855df5f6
- cinder-api now runs under apache2 and no longer as systemd service
- cinder-volume needs explicit backend configuration
- don't install deprecated cinder v1 API endpoints
- clean up some config options
To be added in a follow-up:
- Make backend configuration more flexible
- Replace distro provided wsgi setup with our custom one
Change-Id: I77ac294fd8e1cd4e6bc39667ddfdea21c4daed8a
- Now use cookbook-openstackclient to create endpoints role service and
user
- added domain creation and access granting
- added values to work with identity_v3
- rewrote specs to work again
- added needed keystone_authtoken attributes
- updated README
Change-Id: I2f339055883354c6a8a77daa7967ff279c4d18d9
Depends-On: I0f8955f05de9b33711c54b9a198f45018cceb8e1
Depends-On: If7b4d6e563081a0be9957353d73ef61a9688df56
As a requirement for Ubuntu 16.04, the apt cookbook needs to be at least 4.0
Change-Id: I47416ef32af0e00acbcc366c9acdae306862a56a
Depends-On: I07ad79a93642d0f0c934a864fcb9bcd7b764e35f
Implements: blueprint newton-xenial
The python cookbook is deprecated, so we should get rid of it, in
particular as we do not seem to need it anymore.
Change-Id: I4320035a0fff6479d96215239eec9006b4e79754
* endpoint type (admin, internal, public) and service (identitiy, network etc.)
was switched during refactoring, this patch reverts this unintended switching
* edited bind_service service type from public,internal,admin to 'all'
for default binding to just one service
Change-Id: I4d28b1b2489419c1f033dfcda0effa5a53c537c3
Depends-On: Iec485deaf415e4187a323435cce2b6bbadfc5d42
Depends-On: Ia5bddfc5e2fd77cd6e9e855c680b079f78fc1c3f
Depends-On: I4f97b659361dabd7fac216305d2aad2f1bb98f51
* added endpoint attributes (moved from common)
* removed qpid as a messaging option (can be incuded in a wrapper)
* deleted default attributes from nova.conf.rb originated in
openstack-common
* adapted optimized endpoint logic
* removed rubocop exceptions in recipes and regenerated the
.rubocop_todo.yaml containing all remaining exceptions
* added versionbumb for refactored os-identity and common
* moved version up to 13.0.0 for mitaka release
* removed fedora, suse as supported platform
* adapted the specs (unit tests) to work again
* added new logic into templates/default/cinder.conf.erb
* refactored attributes throughout all recipes that were connected to
the attributes used for the cinder.conf.erb template to adapt the new
template attribute syntax
* moved all attributes from attributes/default.rb that were used in
cinder_conf.erb to attributes/cinder_conf.rb
* refactored attributes to fit upcomming template logic
* refactored recipes to fit upcomming template logic
* removed all attributes from default.rb and cinder.conf.erb which are set
as default in attributes, openstack doc and used to render the template
Depends-On: Ifa5a7f4e1df47a3961976e64f654224864c3dcb4
Depends-On: I3262b2e6f792f37c32a446e6567790b82bdd4613
Depends-On: I0547182085eed91d05384fdd7734408a839a9a2c
Implements: blueprint cookbook-refactoring
Change-Id: Idadc97bd7380d6c4f9f6f33d9c6b1215a5f24772
- According to the bool attribute
node['openstack']['endpoints']['db']['enabled_slave'], enable/disable
nova database slave_connection
- Add the slave_connection generated from db_uri function
Implements: blueprint sql-slave-connection-support
Change-Id: I9520441952993e8c6b4205e6886778815b5a2e4b
Change I1bb94dc1283e50645e4aece600acc52ae17db56b added the config option
default_volume_type with a default value of nil. With this, cinder fails
to create volumes unless a type is explicitly specified. So better only
write this value into the config file if it is set to some non-nil
value.
Change-Id: I7de8c6cc5a424b5b5021675d89a5dba71d72dce0
Currently, when we use GPFSDriver as multi backend volume driver,
cookbook won't create gpfs mount point base directory automatically.
This patch fix this problem.
Closes-Bug: #1476960
Change-Id: I1faf33470747fac6df66854470cf45d35a38f3c1
Oslo.message using rabbit_max_retries and rabbit_retry_interval to
define reconnect rabbitmq server times and interval when can not
connect to rabbitmq server.
Change-Id: I449f7be68dd9c9adbad587a47cf9d9dcc3462369
Closes-bug: #1439968
Cleaned up all the minor rubocop issues, the ones left relate to
complex logic and what I think is a bug in rubocop for nested
vs compact modules/class definitions.
Change-Id: I5ac6d513c3b1397ba7205dc6f661134a93d17741
Cinder volumes are associated with the cinder host that created them.
This unique host id can be changed in the conf file. This patch adds
support to allow that.
Change-Id: I9295ed1bfa24bfac8325bd347a92b5e334a31371
Closes-Bug: #1451967