Commit Graph

167 Commits

Author SHA1 Message Date
Dmitriy Rabotyagov bedc003fb2 Define unique hostname for QManager
Due to the shortcoming of QManager implementation [1], in case of uWSGI
usage on metal hosts, the flow ends up with having the same
hostname/processname set, making services to fight over same file
under SHM.

In order to avoid this, we prepend the hostname with a service_name.
We can not change processname instead, since it will lead to the fight
between different processes of the same service.

[1] https://bugs.launchpad.net/oslo.messaging/+bug/2065922

Change-Id: I0c310abd4c2144a068e75aaea665befeee0a5ff6
2024-05-25 15:21:01 +02:00
Zuul e712535365 Merge "Cleanup old functional tests" 2024-05-21 09:52:46 +00:00
Zuul 179e957e4e Merge "Add tag to enable targeting of post-install config elements only" 2024-05-20 18:15:41 +00:00
Zuul 8f80706565 Merge "Implement variables to address oslo.messaging improvements" 2024-05-20 18:15:40 +00:00
Zuul d37c60bfcb Merge "Add variable to globally control notifications enablement" 2024-05-20 18:10:58 +00:00
Zuul c65b602d9a Merge "Add service policies defenition" 2024-05-20 18:10:56 +00:00
Zuul 83f989b1eb Merge "Add quorum queues support for service" 2024-05-20 18:10:55 +00:00
Dmitriy Rabotyagov d09d1f1ba0 Cleanup old functional tests
We don't run functional tests anymore so it's time to clean-up all
related bits.

Integrated tests should be used instead.

Change-Id: If1d799aec0c2d547c30c13496e45a010c5c0caaa
2024-05-20 16:48:05 +00:00
Andrew Bonney dd58970211 Add tag to enable targeting of post-install config elements only
<service>-config tags are quite broad and have a long execution
time. Where you only need to modify a service's '.conf' file and
similar it is useful to have a quicker method to do so.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/919714
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/919702
Change-Id: Ibd34b8b8d0a25709c59318d4f5f4c9785746d7e5
2024-05-17 16:30:34 +00:00
Dmitriy Rabotyagov d23d637fd4 Implement variables to address oslo.messaging improvements
During last release cycle oslo.messaging has landed [1] series of extremely
useful changes that are designed to implement modern messaging
techniques for rabbitmq quorum queues.

Since these changes are breaking and require queues being re-created,
it makes total sense to align these with migration to quorum queues by default.

[1] https://review.opendev.org/q/topic:%22bug-2031497%22

Change-Id: Iffffbf0c567f68f6e3e26fc7fce4dd5e2317d4f3
2024-05-16 20:50:33 +00:00
Dmitriy Rabotyagov 3a326c054a Add variable to globally control notifications enablement
In order to be able to globally enable notification reporting for all services,
without an need to have ceilometer deployed or bunch of overrides for each
service, we add `oslomsg_notify_enabled` variable that aims to control
behaviour of enabled notifications.

Presence of ceilometer is still respected by default and being referenced.

Potential usecase are various billing panels that do rely on notifications
but do not require presence of Ceilometer.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible-plugins/+/914144
Change-Id: I1bffec218f903ea16cbd06e7abf28b8139024df8
2024-05-16 20:50:29 +00:00
Dmitriy Rabotyagov fa67e0e01d Add service policies defenition
In order to allow definition of policies per service, we need to add variables
to service roles, that will be passed to openstack.osa.mq_setup.

Currently this can be handled by leveraging group_vars and overriding `oslomsg_rpc_policies` as a whole, but it's not obvious and
can be non-trivial for some groups which are co-locating multiple services
or in case of metal deployments.

Change-Id: Ifbda391bf0c91a51ecea5e78ba7311e3d64c8ffc
2024-05-16 20:50:16 +00:00
Dmitriy Rabotyagov 9adc5586ad Add quorum queues support for service
This change implements and enables by default quorum support
for rabbitmq as well as providing default variables to globally tune
it's behaviour.

In order to ensure upgrade path and ability to switch back to HA queues
we change vhost names with removing leading `/`, as enabling quorum
requires to remove exchange which is tricky thing to do with running
services.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/919714
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/919702
Change-Id: I02302332819be71346a256a86ae58fed3892279a
2024-05-16 13:22:21 +00:00
OpenStack Release Bot 2dc162abf2 reno: Update master for unmaintained/zed
Update the zed release notes configuration to build from
unmaintained/zed.

Change-Id: Ie4d66bf19f779e6c4d3df93c16457c51f495511d
2024-05-10 18:56:02 +00:00
Dmitriy Rabotyagov 54e3c21c85 Define constraints file for docs and renos
Right now we are not using any constraints for docs and releasenotes builds.
This has resulted in docs job failures once Sphinx 7.2.0 has been released.

The patch will ensure that constraints are used an we should not face
simmilar issue again.

TOX_CONSTRAINTS_FILE is updated by Release bot once new branch is created,
so it should always track relevant constraints.

Some extra syntax-related changes can apply, since patch is being passed
through ConfigParser, that does not preserve comments and align indenting.


Change-Id: I245b4d7f526380862fce2d88fbcd7ab1b8ed4053
2023-08-17 16:32:17 +02:00
Zuul 32ba37d559 Merge "Fix linters and metadata" 2023-08-14 10:52:51 +00:00
Dmitriy Rabotyagov f5aa36a38d Use proper galera port in configuration
While <service>_galera_port is defined and used for db_setup
role, it's not in fact used in a connection string for oslo.db.

Change-Id: I795e7a7423d3efd5168dd8e8d89b3c86aa13c31f
2023-07-31 15:18:32 +02:00
Dmitriy Rabotyagov 6a25236b25 Fix linters and metadata
With update of ansible-lint to version >=6.0.0 a lot of new
linters were added, that enabled by default. In order to comply
with linter rules we're applying changes to the role.

With that we also update metdata to reflect current state.

Depends-On: https://review.opendev.org/c/openstack/ansible-role-systemd_service/+/888223
Change-Id: I9110294e492a501204c8e92448a2f2929781a509
2023-07-14 18:49:03 +02:00
Dmitriy Rabotyagov 93beaf8c4a Switch jobs to Jammy
We're dropping Ubuntu Focal support early in 2023.2 release,
so we need to switch all jobs to Jammy before this happens.

Change-Id: I77e88c183c1dcdd03a8537c4a6e68b98f0f7f86b
2023-05-25 13:43:05 +02:00
Adrien Cunin e29058b48e Don't install zlibc, it was removed from Debian
Change-Id: If3757269213246f3f54769e12bc93cdc50fe93e1
2023-05-12 15:27:57 +02:00
Damian Dabrowski 0b6f8da608 Add TLS support to manila backends
By overriding the variable `manila_backend_ssl: True` HTTPS will
be enabled, disabling HTTP support on the manila backend api.

The ansible-role-pki is used to generate the required TLS
certificates if this functionality is enabled.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/879085
Change-Id: I38b95b73301d2210f64105c20f389c74498a5345
2023-04-29 18:47:26 +02:00
Zuul 136089ce58 Merge "Remove unused variable" 2023-04-14 13:05:52 +00:00
Jonathan Rosser 543e317014 Remove unused variable
This was introduced when the role was created using os_cinder as
a starting point [1], as has never been used in the manila role.

[1] f9bfb7f0bc

Change-Id: I57df438cd25efd30e0e437470fc34df8fea1317c
2023-04-11 09:04:14 +01:00
Dmitriy Rabotyagov ab4b4a1d25 Ensure service is restarted on unit file changes
At the moment we don't restart services if systemd unit file is changed.

We knowingly prevent systemd_service role handlers to execute
by providing `state: started` as otherwise service will be restarted twice.
With that now  we ensure that role handlers will also listen for systemd
unit changes.

Change-Id: I4eec982a682bfff121f9658c6d4eb3d1db8cb94f
2023-04-10 16:33:54 +02:00
Dmitriy Rabotyagov b8865bde4c Update tox.ini to work with 4.0
With tox release of 4.0, some parameters were deprecated and are ignored now
which causes tox failures. One of the most spread issues we have is using
`whitelist_externals` isntead of `allowlist_externals`


Change-Id: Ibbb153da7fd38b2a7df2b13480f647ab95d96d81
2022-12-27 17:53:21 +01:00
OpenStack Release Bot 3363242b07 Update master for stable/zed
Add file to the reno documentation build to show release notes for
stable/zed.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/zed.

Sem-Ver: feature
Change-Id: Ib73aca403b1f053944ea269287245ac7c7c651ca
2022-12-13 13:16:37 +00:00
Dmitriy Rabotyagov c0a1f262eb Create backends when running against manila_share
For backends creation we verify that API is reachable. With that on real
deployments we disable container we're running against on haproxy.

This results in task failure. To avoid that we add backends when
share/data services for manila. This is done in separate play when
all API backends should be enabled and functioning properly.

Change-Id: I6dcbae2896668f5fbb6f09bffc94cb6e90699e92
Closes-Bug: #1979209
2022-06-23 10:26:22 +02:00
Zuul b5426ccb9b Merge "Remove mention of haproxy-endpoints role" 2022-06-16 23:21:28 +00:00
Dmitriy Rabotyagov f728ca5707 Support service tokens
Implement support for service_tokens. For that we convert
role_name to be a list along with renaming corresponding variable.

Additionally service_type is defined now for keystone_authtoken which
enables to validate tokens with restricted access rules

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible-plugins/+/845690
Change-Id: Ie5ebb4d68ed06cff26462dc55092fda8a9ad2f44
2022-06-15 19:11:22 +02:00
Dmitriy Rabotyagov 0ea23558e7 Remove mention of haproxy-endpoints role
Role was never migrated to usage of haproxy-endpoints role
and included task was used instead the whole time.
With that to reduce complexity and to have unified approach, all mention
of the role and handler are removed from the code.

Change-Id: Ia04bd0a729100ed3f0bade9185b0703ce903635f
2022-06-15 17:01:41 +00:00
Dmitriy Rabotyagov 0db9f1f959 Delegate share type creation to setup host
Instead of running manilaclient on manila host, we're delegating
execution to service_setup_host. This reduce
complexity and remove some requirements for manila hosts.

With that we also replace usage of manilaclient
with openstackclient.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/845998
Change-Id: Ie04d9e1690e0f053e86e28e0bf1d6c3aa43774b0
2022-06-15 14:32:02 +00:00
Dmitriy Rabotyagov 4bff5b4352 Switch sphinx language to en
With sphinx release of 5.0.0, they changed default for language variable
to 'en' from None. With that current None valuable is not valid and should
not be used.


Change-Id: Ic728c71b6d1f44b903ac0ade0ab2516a6cdc16fb
2022-05-30 16:01:29 +02:00
Marc Gariepy 977d2b9369 Cleanup setup.py config
Change-Id: I5b9acf8fab3813169eff3e063875694aa9ab9c72
2022-03-31 10:39:34 -04:00
Jonathan Rosser b37400e2d0 Remove legacy policy.json cleanup handler
Change-Id: I2421c32fcc4aaf745d06708360ac8f03cb126df3
2022-02-02 04:17:27 -05:00
Zuul 77ce3dc017 Merge "Use common service setup tasks from a collection rather than in-role" 2022-01-13 13:35:46 +00:00
Jonathan Rosser 91da6dbee7 Use common service setup tasks from a collection rather than in-role
Change-Id: Ia350d1da1043513eefad6806813dcf1dc7fcd005
2022-01-12 17:30:00 +00:00
Jonathan Rosser f07b0f764a Refactor use of include_vars
Use a first_found lookup instead of a with_first_found loop so that
the 'paths' parameter can be used.

This ensures that only vars from the role are included, and not vars
from a parent calling role. This can happen when a parent role has
a higher priority vars file available for inclusion than the role
it calls.

Change-Id: I4983e2e13eb3ec29b0417094cf66629ce0f89052
2022-01-12 08:28:46 +00:00
Dmitriy Rabotyagov a422c42665 Refactor galera_use_ssl behaviour
With PKI role in place in most cases you don't need to explicitly
provide path to the CA file because PKI role ensures that CA is trusted
by the system overall. In the meanwhile in PyMySQL [1] you must either
provide CA file or cert/key or enable verify.

Since current behaviour is to provide path to the custom CA we expect
certificate being trusted overall. Thus we enable cert verification when
galera_use_ssl is True.

[1] 78f0cf99e5/pymysql/connections.py (L267)

Change-Id: I94b3f8ba5116cdfb94e9d0dc575bd7edb1d27b3c
2021-12-06 20:52:14 +02:00
Zuul 83fba27a14 Merge "Updated from OpenStack Ansible Tests" 2021-12-06 18:41:07 +00:00
Zuul 82bbca6961 Merge "Refactor definition of lock path" 2021-12-06 18:41:05 +00:00
OpenStack Proposal Bot 7593b2a1d2 Updated from OpenStack Ansible Tests
Change-Id: I5653b5209c227d414b3334a45dfe60b0f35b80d2
2021-12-06 09:00:13 +00:00
Damian Dabrowski 48a8c0627a Database connection pooling improvements
- Implemented new variable ``connection_recycle_time`` responsible for SQLAlchemy's connection recycling
- Set new default values for db pooling variables which are inherited from the global ones.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/819424
Change-Id: If245cd3f12a919933d912205dd60f1e02f555f7c
2021-12-06 09:00:04 +00:00
Dmitriy Rabotyagov 58c289d7cb Refactor definition of lock path
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/819300
Depends-On: https://review.opendev.org/c/openstack/ansible-role-systemd_service/+/819298
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/820008
Change-Id: I495f99d1378233d1b5d6ebc8ef101f683129a84f
2021-12-06 08:59:58 +00:00
Dmitriy Rabotyagov 0ccd0c0360 Use config_template as a collection
Since we still use ceph-ansible that has their own implementation of
config_template module it's worth to use mentioned module as a collection
explicitly.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/820010
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/820192
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/820417

Change-Id: I4198e13defb5b2f7fb443364027ccf902bf19c90
2021-12-06 08:59:08 +00:00
Dmitriy Rabotyagov b3cd636e45 Disable CentOS check
CentOS check fails with OOM. In order to merge required stuff
we temporary disable CentOS check until sort out the way how to reduce
RAM consumption by the check.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/820010
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/820192
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/820417
Change-Id: Ifd03510495483f90fce22328bea08b4e0fdafe49
2021-12-06 08:58:52 +00:00
OpenStack Proposal Bot 415b5ad7a8 Updated from OpenStack Ansible Tests
Change-Id: I740d54d0610c3fc757f6569e927f0e9b31887c51
2021-06-03 10:46:00 +00:00
Dmitriy Rabotyagov 286414c2a6 Set manila_backends to empty dict by default
This simplifies logic across the role and not verify if variable is
defined each time we're attempting to use it.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/787341
Change-Id: I6db4ad6e6389b1ff63dc52a1e48c477a97905d17
2021-05-20 18:52:19 +00:00
Zuul 91b53f2b6c Merge "Remove ceph-fuse requirement" 2021-05-20 09:17:16 +00:00
Zuul 8c893d6da5 Merge "Add variables for rabbitmq ssl configuration" 2021-05-19 15:04:01 +00:00
Zuul 2bcae23c0f Merge "setup.cfg: Replace dashes with underscores" 2021-05-19 11:38:34 +00:00