Commit Graph

496 Commits

Author SHA1 Message Date
Dmitriy Rabotyagov 59606f0957 Adopt for usage openstack_resources role
With efforts to create a resources in same, unified way,
we convert tempest role to use openstack_resources
for creating and managing openstack resources, like projects, flavors,
networks, images, etc. This should reduce maintenance costs
in case of futher collection updates and unify approach.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible-plugins/+/878794
Change-Id: I762ded9b6099ea55e8a19bfb82473b950155eaa4
2024-02-01 10:15:56 +00:00
Dmitriy Rabotyagov 34e0def6ec Remove obsoleted provider drivers
amphorav1 driver has been dropped from octavia early in 2023.2 cycle [1]

[1] 6c0515c988

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/900399
Change-Id: I7afeaca12dd65e5455359e22c21a77191381bc73
2023-12-05 14:06:47 +00:00
Dmitriy Rabotyagov e3c74d18e3 Adjust condition for availability_zone definition
We're checking if octavia_amp_availability_zone is defined, while the
variable is defined in defaults, so there is no clean way to undefine
the availability_zone except to use config overrides and define to
none.
So whe change condition in a way to allow empty value to be treated as
False which would result in availability_zone being undefined in the
config.

Change-Id: I86ffd71d6791dec700c381b695ab5a4bca8051a3
2023-11-07 19:11:02 +00:00
Zuul 8da3bddd99 Merge "Add quorum queues support for service" 2023-10-26 11:58:28 +00:00
Zuul 7710ff484f Merge "Drop Neutron oslomsg configuration" 2023-10-26 10:17:06 +00:00
Dmitriy Rabotyagov c0783fcdf5 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.

Change-Id: I4781a0c23274b145970b3269e517c2a62497acc4
2023-10-20 12:34:55 +00:00
Dmitriy Rabotyagov a6cb51d27a Drop Neutron oslomsg configuration
These options were used for lbaasv2 and are not used in Octavia code
for quite some time.

Change-Id: Ie6f21fe9b46c55c37ee88ad911e7c5aa56b9db9c
2023-10-20 10:48:46 +00:00
Dmitriy Rabotyagov ce5c701ab4 Add security rule for octavia healthmanager
Amphora does report back it's status to Octavia healthmanager through
octavia_health_manager_port. This outgoing traffic from Amphora must be
allowed to show LB stats and operational_status.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible-plugins/+/896017
Change-Id: Ib6b8547b69949f7af0ba0f7f436b4286d3baccb7
2023-10-05 07:01:19 +00:00
Dmitriy Rabotyagov 3a7c5e6634 Fix example playbook linters
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible-plugins/+/896017
Change-Id: I19aa9c5e915aa7e71617de6556d1eccff1a93ebb
2023-10-05 07:01:07 +00:00
Dmitriy Rabotyagov 1ae94217ec 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: I94cc61d88b0ec54bde01477e8fba35e341afffa2
2023-08-17 14:57:08 +00:00
Dmitriy Rabotyagov 138696d0f5 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: Ia704b63838c8730039e135eb38e170204d5a30e2
2023-08-17 16:32:22 +02:00
Dmitriy Rabotyagov d94e57f17b 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.

Change-Id: Id8215882ee528d4c3055479e770c7432616649ba
2023-07-17 15:38:00 +02:00
Zuul 048f9d548e Merge "Add TLS support to octavia backends" 2023-05-08 11:51:23 +00:00
Damian Dabrowski ee554649bd Add TLS support to octavia backends
By overriding the variable `octavia_backend_ssl: True` HTTPS will
be enabled, disabling HTTP support on the octavia 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: Id6c187cad4e444fb83ca1f938bd13bb9b73652b3
2023-04-29 18:43:06 +02:00
Dmitriy Rabotyagov 8499e1713e Switch default provider to amphorav2
Amphorav1 has been deprecated and is removed early at the
beginning of the 2023.2 cycle. With that Antelope is perfect time for
switching the default.

[1] 6c0515c988

Change-Id: I133f20a6d971832138708101e6a8380d23e75cf2
2023-04-24 16:16:20 +02:00
Dmitriy Rabotyagov cea4f2e358 Change default CIDR for security_group
At the moment security group allows to access Amphora SSH/API
from any network which is insecure. We're changing default for
security groups to allow access only from Octavia Management
network.

Change-Id: I6ea6ab4ec1c28a3b354d40f6744434eefb05fcfe
2023-04-19 09:51:08 +00:00
Dmitriy Rabotyagov 7c46b9460d Do not limit IP prefix for DHCP rule
In case it's needed to limit access to DHCP servers, rules must be
way more complex then this one, since DHCP uses broadcast.

To avoid complexity, let's just avoid defining remote_ip_prefix
that allows egress traffic for DHCP.

Change-Id: I280c064b4d93bcd78092f02a928d5d6dfb4fda68
2023-04-19 11:50:46 +02:00
Dmitriy Rabotyagov c672dc1848 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: I4a3346c90825a4bf0b416943286696fa529f526d
2023-04-14 19:26:26 +00:00
Dmitriy Rabotyagov aeebb5bdd4 Adopt info modules fetch to collection 2.0
With ansible-collection version 2.0 return of project_info module
has changed. We need to adopt usage of module return to the new format.

We also add security group rule for dhcp, since in case DHCP is enabled
for the network, it won't be provided in metadata on config-drive anymore.

Change-Id: I861797fdddbf2c82ef7b1409df577475e7424414
2023-04-14 21:20:16 +02:00
OpenStack Release Bot 4a686acc56 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: I68231d7943454098b344fa51f75bdec7e2efa3ee
2022-12-13 13:19:03 +00:00
Zuul 910128fa7c Merge "Change defaults for octavia topology and affinity" 2022-12-12 18:25:08 +00:00
Zuul 21e174c25b Merge "Add coordination to octavia" 2022-12-12 15:34:04 +00:00
Dmitriy Rabotyagov b1a5d10f33 Change defaults for octavia topology and affinity
In most of production deployments it's preferable to have ACTIVE_STANDBY
topology with enable anti-affinity to ensure that loadbalancer
can survive compute node downtime and won't lead to service disruption.

Without these settings it will take quite some time to re-spawn failed
Amphora.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/866061
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/867052
Change-Id: I4fa437117dce1c973512c09b1bc7d43d411276da
2022-12-10 19:10:49 +00:00
Dmitriy Rabotyagov aeb1dbf1dd Add coordination to octavia
This also enables usage of amphorav2 when coordination is
available.

Depends-On: https://review.opendev.org/c/openstack/ansible-role-zookeeper/+/867049
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/867052
Change-Id: I1234d36c58da3f6754cda1951ee4cc49f979ae0c
2022-12-08 20:47:00 +00:00
Zuul 166fe30291 Merge "Enable /healthcheck for Octavia API" 2022-12-01 15:06:11 +00:00
Zuul a148ecf90e Merge "Remove redundant vars line" 2022-12-01 14:54:40 +00:00
Dmitriy Rabotyagov b08e95a972 Enable /healthcheck for Octavia API
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/864553
Change-Id: Ie7a6dd78d5af82a546e4d6a19ec5b256df8f64e6
2022-11-25 16:32:43 +00:00
Erik Berg 2aed05ce6c Remove redundant vars line
This line snuck in with I5cc0b1bde814abb0a4afe1567b9b23230a57f275
probably to bring it in line with other OSA roles, but should already
be covered by the distribution_major_version line above.

Change-Id: I7f719b3fbd7e89ce96b84c9080049888aeda7ee6
2022-11-25 16:32:35 +00:00
Bjoern Teipel 2f1a3b4db1 Adding octavia_provider_network_mtu-parameter parameter
The `octavia_provider_network_mtu-parameter` defaults to 1500
to not accidentially use `global_physnet_mtu` on deployment with
large MTU settings

Change-Id: I9fa33c5ee76197191f1e66b7a70a4c1c0a5fa394
2022-11-25 16:32:24 +00:00
Dmitriy Rabotyagov c31bbc215c Adopt output structure to new collections version
With commit [1] to collection output structure of networks_info module
has been changed. With that we adpot to the new format.

Return values for keypair have also changed

[1] 9272146cf7

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/864553
Change-Id: Ic22ec379983e43aa5f2b55fd4543b4aa70762354
2022-11-25 11:57:49 +00:00
Dmitriy Rabotyagov 87e78ee34c 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: I8cd6c47c64601089173671652a463ecc291d8ca1
2022-06-17 13:40:17 +00:00
Dmitriy Rabotyagov fbdfd529d8 Set CentOS 9 Stream as NV
Currently CentOS 9 Stream hits libvirt bug [1] that occurs on attaching
interface to running VM. Octavia is most affected by that as this is
part of usual workflow.
Fix for the bug has been already proposed and should be released
quite soon. Not to spend a lot of time on that, we rather wait for new
libvirt version to be released  for CentOS 9 Stream and until then
set jobs as NV.

[1] https://bugzilla.redhat.com/show_bug.cgi?id=2092856

Change-Id: I9dd6fcea23154f781ec111a0927a26aba28954f1
2022-06-17 14:35:44 +02:00
Zuul 2490e5a64e Merge "Use PKI role for certificate generation" 2022-06-08 01:24:14 +00:00
Dmitriy Rabotyagov 757aecd58b Use PKI role for certificate generation
This patch replaces usage of role-specific tasks for managing
certificates to PKI role.

This will allow to unify certificates management with other services
along with simplify management of code.

However, this patch does not contain migration path, which should
be handled separately.

Depends-On: https://review.opendev.org/c/openstack/ansible-role-pki/+/838713
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/843711
Change-Id: I96c6030722661eb7ffdb31ac75e09785871179d5
2022-06-02 08:31:07 +00:00
Zuul 2bcdfdb61a Merge "Move installation variables collection to beginning" 2022-05-30 22:30:07 +00:00
Dmitriy Rabotyagov 24009cfef6 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: I7d612a82e0b79ad1d34f9cbd75c5e19f201d7741
2022-05-30 16:01:40 +02:00
Dmitriy Rabotyagov f23ca9737d Move installation variables collection to beginning
We need to collect installation method variables as early as we can as
we rely on them later on in the play.

Change-Id: I0fa1b7b25a4b6ced5606018410825e7cf2eac54a
2022-05-28 08:05:04 +02:00
Zuul 47ac60ca20 Merge "Add flexability for octavia cinder variable." 2022-05-27 11:48:48 +00:00
Zuul 2a4677e0d4 Merge "Fix condition for deleting old amp images" 2022-05-23 10:19:13 +00:00
siavash sardari 3e10d40b10 Add flexability for octavia cinder variable.
Introduces 3 new variables cinder_default_availability_zone, octavia_cinder_volume_size and octavia_cinder_volume_type. using these variables, enables Octavia to use different Cinder configurations.

Change-Id: I8162e83d39075cd99c516b84c39ed868306283c3
2022-05-23 12:52:04 +04:30
Jonathan Rosser 9d999d0bae Fix condition for deleting old amp images
Change-Id: Ic5c9b809f90dae415ccc72233342ea3242c0b78f
Closes-Bug: 1967270
2022-05-17 16:49:09 +01:00
OpenStack Proposal Bot 5547127fb4 Updated from OpenStack Ansible Tests
Change-Id: Ia865b0d11af557c5760258f6fc0684bb161345c8
2022-05-17 11:14:32 +00:00
Zuul 7846562859 Merge "Make octavia_provider_network better configurable" 2022-05-11 13:52:42 +00:00
Dmitriy Rabotyagov ebac6ccb5e Fix distro support option for Octavia
Distro instalaltion has been broken for a while and CI disabled for it.
With this commit we're fixing path and returning back
CI testing of it.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/837845
Change-Id: Ia715e0506e45ead6ed8ecffac3fbd70e9849da13
2022-05-11 07:49:39 +00:00
Dmitriy Rabotyagov 941e671e06 Make octavia_provider_network better configurable
For vlan scenraio we can't use  octavia_provider_network_name for
octavia_provider_network but it's pretty big override, which might be
more handy with having an extra variable, that will be used inside it.

Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/787199
Change-Id: Ib5627dc3b37626e056c3cfe9ce54ee6a7ff25dd5
2022-05-10 18:45:51 +02:00
Jonathan Rosser 4ba4409e46 Change octavia private key ciphers to type 'auto'
Modern ansible only supports the 'cryptography' backend for the
openssl_privatekey module. In this case, the 'cipher' module
parameter must be set to 'auto'.

Change-Id: I2bfe5fa57c7deb201f56f82d5699c91fcccb766d
2022-04-04 13:49:02 +01:00
Marc Gariepy 4b8ba186f8 Cleanup setup.py config
Change-Id: I5ed9926f8cf40c96c4e377a8592bee475edc871b
2022-03-31 10:40:28 -04:00
Zuul 55fde3ba2a Merge "Remove legacy db pooling variables" 2022-02-04 00:19:35 +00:00
Jonathan Rosser 57400fb6a6 Remove legacy policy.json cleanup handler
Change-Id: Ia37876caa7b627e66d5e703262a8b060c46fa25d
2022-02-02 04:21:46 -05:00
Jonathan Rosser d736c64072 Remove legacy db pooling variables
Change-Id: I7f7e9a5a4a12afff994f548abff2482818a43ccb
2022-02-01 04:20:55 -05:00