Commit Graph

153 Commits

Author SHA1 Message Date
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
Zuul 019e08ef48 Merge "Use ansible_facts[] instead of fact variables" 2021-05-19 11:38:31 +00:00
Zuul afb8fe7ef3 Merge "[reno] Stop publishing release notes" 2021-05-19 10:05:58 +00:00
Zuul 3caecbf1e0 Merge "Remove references to unsupported operating systems" 2021-05-19 08:26:21 +00:00
dmitriy 9c3b6d6860 [reno] Stop publishing release notes
Since we copy all release notes to the integrated repo there is not need
in publishing release notes for each repository. We should only verify their
validity and linting.


Change-Id: I5234e70e508a1026acb5a402ae406e47e510c2e7
2021-05-18 16:34:04 +00:00
Dmitriy Rabotyagov a5ba4dc4cd Remove ceph-fuse requirement
Since we don't need to mount and create volumes directory for
manila, ceph-fuse package is not required anymore as well.

Change-Id: I5cd92bd90ab19a32f7488ab56dbb6b005253e2c3
2021-05-18 16:33:49 +00:00
Jonathan Rosser 590e0235ab Use ansible_facts[] instead of fact variables
See https://github.com/ansible/ansible/issues/73654

Change-Id: I175072167602b6ec400d21b9350533a58901f890
2021-05-18 16:32:14 +00:00
Jonathan Rosser e85642f80c Remove references to unsupported operating systems
All references to Gentoo, SUSE, Debian stretch and Centos-7  are removed.
Conditional tasks, ternary operators and variables are simplified where possible
OS specific variables files are generalised where possible

Change-Id: I508c7aea34bb706b58fc69be8bfb6c06d50f2f40
2021-05-18 16:32:05 +00:00
Jonathan Rosser bb870ea34e Add variables for rabbitmq ssl configuration
Change-Id: I419cc8f2920bb2a5108cacb95e41a9965b3dd659
2021-05-18 16:31:24 +00:00
Jonathan Rosser f15d62e61e Switch default virtualenv to python3
Change-Id: I9eb6fcd712a868e28735d38261c21582d8751209
2021-05-18 16:30:47 +00:00
yangyawei 58d9c84d71 setup.cfg: Replace dashes with underscores
Setuptools v54.1.0 introduces a warning that the use of dash-separated
options in 'setup.cfg' will not be supported in a future version [1].
Get ahead of the issue by replacing the dashes with underscores. Without
this, we see 'UserWarning' messages like the following on new enough
versions of setuptools:

  UserWarning: Usage of dash-separated 'description-file' will not be
  supported in future versions. Please use the underscore name
  'description_file' instead

[1] https://github.com/pypa/setuptools/commit/a2e9ae4cb

Change-Id: Ibe4ce100cfad933dfaeaba236d7921711df491d5
2021-05-16 14:47:03 +08:00
Dmitriy Rabotyagov de29f07d77 [goal] Deprecate the JSON formatted policy file
As per the community goal of migrating the policy file
the format from JSON to YAML[1], we need to replace policy.json to
policy.yaml and remove deprecated policy.json.

config_template has been choosen instead of the copy, since it can
properly handle content that has been lookuped.

We make a separate task not to restart service when it's not needed.

CephFS Native hook has been removed since [2] as manila leverages MGR
now and doesn't require having directory in share.

Additionally bionic test is removed as we don't have Octopus infra
mirrors for it.

[1] https://governance.openstack.org/tc/goals/selected/wallaby/migrate-policy-format-from-json-to-yaml.html
[2] a830710939

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/791202
Change-Id: I7a1807e4b984e31cb6250132f35d4c27f0b69b0c
2021-05-13 13:11:04 +00:00
Jonathan Rosser f404eb46c4 Move manila pip packages from constraints to requirements
This is necessary to use the new pip resolver

Change-Id: I78f7cb313da7835d96be95436ae69c0a6d8cfa25
2021-01-25 10:09:11 +00:00
Dmitriy Rabotyagov b5aed5c130 Use global service variables
Instead of overriding each service separatelly it might make
sense for deployers to define some higher level variable that
will be used first or fallback to default variable.

Change-Id: Ie2c30dcc3640361b91e602125e98996c897f0f06
2021-01-18 11:36:42 +02:00
Zuul dfc29c7bac Merge "Add Manila key generation and distribution" 2020-11-18 16:26:18 +00:00