6622 Commits

Author SHA1 Message Date
Ghanshyam Mann
283fa242ca Remove system scope token to access services
As per the RBAC new direction in Zed cycle, we have dropped the
system scope from API policies and all the policies are hardcoded
to project scoped so that any user accessing APIs using system scope
will get 403 error. It is dropped from all the OpenStack services
except for the Ironic service which will have system scope and to
support ironic only deployment, we are keeping system as well as project
scope in Keystone.

Complete discussion and direction can be found in the below gerrit
change and TC goal direction:

- https://review.opendev.org/c/openstack/governance/+/847418
- https://governance.openstack.org/tc/goals/selected/consistent-and-secure-rbac.html#the-issues-we-are-facing-with-scope-concept

As phase-2 of RBAC goal, services will start enabling the new
defaults and project scope by default. For example: Nova did in
- https://review.opendev.org/c/openstack/nova/+/866218

Kolla who start accessing the services using system scope token
- https://review.opendev.org/c/openstack/kolla-ansible/+/692179

This commit partially revert the above change except keeping
system scope usage for Keystone and Ironic. Rest all services are changed
to use the project scope token.

And enable the scope and new defaults for Nova which was disabled
by https://review.opendev.org/c/openstack/kolla-ansible/+/870804

Change-Id: I0adbe0a6c39e11d7c9542569085fc5d580f26c9d
2023-01-26 17:52:00 -06:00
Zuul
38ccebb8cb Merge "Add systemd container control" 2023-01-25 18:43:47 +00:00
Zuul
99d1e3c710 Merge "Adding optional delay between l3 agent restarts" 2023-01-25 14:08:06 +00:00
Zuul
cab09e31dc Merge "Add ability to configure rabbitmq" 2023-01-25 11:20:23 +00:00
Alex-Welsh
391aa4677f Adding optional delay between l3 agent restarts
This change serialises the neutron l3 agent restart process and adds a
user configurable delay between restarts. This can prevent connectivity
loss due to all agents being restarted at the same time.

Routers increase the recovery time, making this issue more prevalent.

Change-Id: I3be0ebfa12965e6ae32d1b5f13f8fd23c3f52b8c
2023-01-23 09:14:59 +00:00
Stanislav Dmitriev
0b62db7cc4 Set scheduler.max_attempts for nova conductor
In order to honour configured max number of attempts
it has to be presented in nova.conf inside of
nova_conductor container, otherwise the default value
of 3 will be used

Closes-Bug: #2003587
Change-Id: I928af332b8658223444594f96417830233057284
2023-01-20 17:10:52 -05:00
Zuul
32dce70f09 Merge "Drop skydive" 2023-01-19 10:26:01 +00:00
Martin Hiner
4866017e52 Add systemd container control
This commit adds SystemdWorker class to kolla_docker ansible module.
It is used to manage container state via systemd calls.

Change-Id: I20e65a6771ebeee462a3aaaabaa5f0596bdd0581
Signed-off-by: Ivan Halomi <i.halomi@partner.samsung.com>
Signed-off-by: Martin Hiner <m.hiner@partner.samsung.com>
2023-01-19 10:38:41 +01:00
Zuul
08267a59ce Merge "Stop firewalld config during kolla genconfig" 2023-01-18 16:26:19 +00:00
Zuul
1b5f64c013 Merge "Remove use_forwarded_for configuration option" 2023-01-18 13:15:56 +00:00
Zuul
7c79d73ec1 Merge "Remove [trustee]/auth_uri option from heat.conf" 2023-01-18 13:09:55 +00:00
Michal Arbet
701dc20f50 Add ability to configure rabbitmq
As rabbitmq's configuration file is not ini or yaml file,
there is no option to extend configuration by new config
options via merge_configs or merge_yaml.

This patch moves config options to dictionary
so it can be overriden in /etc/kolla/globals.yml.

Change-Id: I5cd772f4fb80a0e200fb24d67be735ca81e3fdeb
2023-01-17 22:03:54 +01:00
Pierre Riteau
941abf9ec2 Disable new defaults and scope for Nova API policies (RBAC)
Nova changes to RBAC [1] are breaking Kolla Ansible and causing most CI
jobs to fail. Disable these changes until we can adapt.

[1] https://review.opendev.org/c/openstack/nova/+/866218

Change-Id: I506697d2b374e74a6b066c788bd2d61edc8d4876
2023-01-17 16:14:49 +01:00
Pierre Riteau
943fedee62 Remove [trustee]/auth_uri option from heat.conf
According to the code, docs and oslo-config-validator, this
configuration option is not supported.

Change-Id: I34410e5267d527ec629748f35771f227183810b6
2023-01-16 13:30:56 +01:00
Pierre Riteau
bbe8374fe9 Remove use_forwarded_for configuration option
This option has never been supported by Glance.

Change-Id: I08113292ec862d6ef72b870dcf12577bf02d3771
2023-01-16 13:20:18 +01:00
Zuul
24dc34615a Merge "Fix issue with genconfig and octavia_auto_configure" 2023-01-16 12:17:58 +00:00
Zuul
383dfc21d6 Merge "Fix prechecks in check mode" 2023-01-16 11:14:45 +00:00
Will Szumski
2bf4d4db4e Fix issue with genconfig and octavia_auto_configure
Makes sure the facts required to generate octavia.conf are available
when using genconfig.

This change also ensures that the necessary tasks run when using Ansible
check mode.

Closes-Bug: #1987299
Change-Id: Ib8fbee2d3abdcfd2eae0f9b3e9b69eeb0e3086e0
2023-01-16 09:11:27 +01:00
Matt Crees
09df6fc1aa Add a flag to handle RabbitMQ high availability
A combination of durable queues and classic queue mirroring can be used
to provide high availability of RabbitMQ. However, these options should
only be used together, otherwise the system will become unstable. Using
the flag ``om_enable_rabbitmq_high_availability`` will either enable
both options at once, or neither of them.

There are some queues that should not be mirrored:
* ``reply`` queues (these have a single consumer and TTL policy)
* ``fanout`` queues (these have a TTL policy)
* ``amq`` queues (these are auto-delete queues, with a single consumer)
An exclusionary pattern is used in the classic mirroring policy. This
pattern is ``^(?!(amq\\.)|(.*_fanout_)|(reply_)).*``

Change-Id: I51c8023b260eb40b2eaa91bd276b46890c215c25
2023-01-13 15:40:08 +00:00
Mark Goddard
46aeb9843f Fix prechecks in check mode
When running in check mode, some prechecks previously failed because
they use the command module which is silently not run in check mode.
Other prechecks were not running correctly in check mode due to e.g.
looking for a string in empty command output or not querying which
containers are running.

This change fixes these issues.

Closes-Bug: #2002657
Change-Id: I5219cb42c48d5444943a2d48106dc338aa08fa7c
2023-01-12 14:27:36 +00:00
Zuul
74f64a19f1 Merge "ovn: add ovn-monitor-all variable" 2023-01-12 12:33:43 +00:00
Jack Hodgkiss
86870bd7f8
Stop firewalld config during kolla genconfig
Prevent the haproxy-config role from attempting to modify firewalld when
running kolla-ansible genconfig.

Closes-Bug: #2002522
Change-Id: Ie8a524cc944aa8cb9cf0999b1b8da79f30b40092
2023-01-11 12:03:49 +00:00
Erik Berg
73ba96e23a
iscsi: Use assert on checks for readability
assert will also fail when we're not meeting the conditions, makes
clear what we're actually testing, and isn't listed as a skipped task
when the condition is ok.

Change I940b1d3eceb98e16fa366c243672f588b1412d70 dropped CentOS 7,
so now we're just asserting that it's not RedHat.

Change-Id: Iec4e9a6922b67f7c9eb79f580fffbcc8160529e9
2023-01-09 22:40:06 +01:00
Erik Berg
984612f084
loadbalancer: Use assert on checks for readability
assert will also fail when we're not meeting the conditions, makes
clear what we're actually testing, and isn't listed as a skipped task
when the condition is ok.

Change-Id: Ia72c7052d7f9b8c7d86d74a15dcd9e003178972b
2023-01-09 21:47:10 +01:00
Erik Berg
391f49c949
neutron: Use assert on checks for readability
assert will also fail when we're not meeting the conditions, makes
clear what we're actually testing, and isn't listed as a skipped task
when the condition is ok.

Change-Id: I3e396f1c605d5d2644e757bbb3d954efe537b65e
2023-01-09 19:49:15 +01:00
Erik Berg
0573356d16
ansible: Use assert on checks for readability
assert will also fail when we're not meeting the conditions, makes
clear what we're actually testing, and isn't listed as a skipped task
when the condition is ok.

Change-Id: I20a48bb2eaa3715c6351f5ede04c191ea0a10d3d
2023-01-09 19:45:54 +01:00
Erik Berg
50d44205a9
host_os: Use assert on checks for readability
assert will also fail when we're not meeting the conditions, makes
clear what we're actually testing, and isn't listed as a skipped task
when the condition is ok.

Change-Id: I7d316e11a733c63133cc80677ec1e790e76bf8c6
2023-01-09 19:44:42 +01:00
Erik Berg
e0538c81f3
rabbitmq: Use assert on checks for readability
assert will also fail when we're not meeting the conditions, makes
clear what we're actually testing, and isn't listed as a skipped task
when the condition is ok.

Change-Id: I4c919b523dde2602c81179ab3d28b913650b4c9f
2023-01-09 19:43:32 +01:00
Erik Berg
8d29f0718c
zun: Use assert on checks for readability
assert will also fail when we're not meeting the conditions, makes
clear what we're actually testing, and isn't listed as a skipped task
when the condition is ok.

Change-Id: Iffb84aa14b930eb82cf2043add721c1717ca6c74
2023-01-09 19:41:46 +01:00
Michal Nasiadka
673ca8c7e7 Drop skydive
Change-Id: I8855bd60c2fd77f33fb55d4123131a94327bd166
2023-01-05 14:55:53 +01:00
Zuul
2b88144c05 Merge "Explicitly set the value of heartbeat_in_pthread" 2023-01-05 13:02:20 +00:00
Matt Crees
8b8b4a8217 Explicitly set the value of heartbeat_in_pthread
The ``[oslo_messaging_rabbit] heartbeat_in_pthread`` config option
is set to ``true`` for wsgi applications to allow the RabbitMQ
heartbeats to function. For non-wsgi applications it is set to ``false``
as it may otherwise break the service [1].

[1] https://docs.openstack.org/releasenotes/oslo.messaging/zed.html#upgrade-notes

Change-Id: Id89bd6158aff42d59040674308a8672c358ccb3c
2023-01-05 09:18:13 +00:00
Zuul
29e96d89b1 Merge "Integrate oslo-config-validator" 2023-01-03 17:40:00 +00:00
Zuul
5b738f6e6b Merge "Remove AvailabilityZoneFilter from enabled_filters" 2023-01-03 16:50:47 +00:00
Zuul
066a24ae1f Merge "Fix some neutron configuration options" 2023-01-02 11:40:56 +00:00
labedz
20355edb2b ovn: add ovn-monitor-all variable
Setting ovn-monitor-all to 'true' will configure
ovn-controller to monitor all OVS database records
unconditionally. That will release some CPU resource
from OVS Southbound DB but will increase number of events
coming to ovn-controller.

Default value is 'false'.

Change-Id: I291e166013d8c88f00e84ceaf308251c352c9a79
2022-12-22 10:13:15 +00:00
Matt Crees
6c2aace8d6 Integrate oslo-config-validator
Regularly, we experience issues in Kolla Ansible deployments because we
use wrong options in OpenStack configuration files. This is because
OpenStack services ignore unknown options. We also need to keep on top
of deprecated options that may be removed in the future. Integrating
oslo-config-validator into Kolla Ansible will greatly help.

Adds a shared role to run oslo-config-validator on each service. Takes
into account that services have multiple containers, and these may also
use multiple config files. Service roles are extended to use this shared
role. Executed with the new command ``kolla-ansible validate-config``.

Change-Id: Ic10b410fc115646d96d2ce39d9618e7c46cb3fbc
2022-12-21 17:19:09 +00:00
Pierre Riteau
517b0ec0d9 Remove AvailabilityZoneFilter from enabled_filters
The AvailabilityZoneFilter scheduler filter was deprecated in Xena [1].

[1] https://review.opendev.org/c/openstack/nova/+/745605

Change-Id: I86b6c772a15911d88834bd315e778b3919803422
2022-12-20 09:33:37 +01:00
Pierre Riteau
b6c52323df cloudkitty: set cafile for fetcher_keystone
Without this setting, the keystone fetcher fails to authenticate when
using internal TLS with a local CA.

Closes-Bug: #2000097

Change-Id: Ia709f450c3e5b73e145e89a305cd038c05507dc6
2022-12-19 22:24:14 +01:00
Christian Berendt
73bc7ec71a Add service-images-pull tag to tasks in the service-images-pull role
We sometimes have the requirement that images should explicitly not
be pulled. Using the service-images-pull tag, it is now possible to
skip the actual pull task by using --skip-tags.

Change-Id: Ia00a5ecbcb944c252cd9d0366d8cf1e7ff6327f7
2022-12-19 20:13:17 +01:00
Michal Nasiadka
a3f0511cd1 Remove shebang to properly support venv in ansible-core 2.13+
See https://github.com/ansible/ansible/pull/76677

Change-Id: If822dcfc4c1abf7a22be35ffd90fd05ee46cb0d9
2022-12-13 18:21:12 +01:00
Pierre Riteau
a2739db0e8 Fix generation of OpenSearch Dashboards config
The opensearch config playbook was iterating over opensearch_services,
generating a file named opensearch-dashboards.yml containing an empty
JSON dictionary. The next task was generating opensearch_dashboards.yml
which is actually used by OpenSearch Dashboards.

Remove with_dict in the first task to only generate opensearch.yml.

Change-Id: I39cf74916630d27cd34ce0783ba8c3c0d20bbddc
2022-12-13 15:22:56 +01:00
Michal Nasiadka
f128d19957 Remove kafka, storm, zookeeper
Their cleanup has been added to monasca cleanup command.

Change-Id: I19a846e2683ae70b33ca64d2aba7ac71eb724588
2022-12-08 06:50:15 +00:00
Zuul
a1910abe35 Merge "ovn: Change NB/SB connection setup to allow usage of inactivity probe" 2022-12-07 15:49:41 +00:00
Zuul
113242c864 Merge "Replace ElasticSearch and Kibana with OpenSearch" 2022-12-01 14:38:51 +00:00
Michal Nasiadka
e1ec02eddf Replace ElasticSearch and Kibana with OpenSearch
This change replaces ElasticSearch with OpenSearch, and Kibana
with OpenSearch Dashboards. It migrates the data from ElasticSearch
to OpenSearch upon upgrade.

No TLS support is in this patch (will be a followup).

A replacement for ElasticSearch Curator will be added as a followup.

Depends-On: https://review.opendev.org/c/openstack/kolla/+/830373

Co-authored-by: Doug Szumski <doug@stackhpc.com>
Co-authored-by: Kyle Dean <kyle@stackhpc.com>
Change-Id: Iab10ce7ea5d5f21a40b1f99b28e3290b7e9ce895
2022-12-01 10:27:50 +00:00
Michal Nasiadka
b32d456ea2 ovn: Change NB/SB connection setup to allow usage of inactivity probe
We have been using --db-nb-create-insecure-remote=yes - that results
a TCP method is set by ovn-ctl script to run ovsdb-server.

Downside is - we can't configure inactivity probe on that connection.

Closes-Bug: #1917484
Change-Id: I550aa4fe92aadea2a49ca5aff49c0183609b9470
2022-11-30 11:01:22 +00:00
Zuul
de7d9c237c Merge "Removal of dockerSDK check for other container engines" 2022-11-29 14:00:35 +00:00
Michal Nasiadka
63a7968d8d ovn: Break out role into ovn-db and ovn-controller roles
Instead of handling everything in one role - let's have small
fit-for-purpose roles, because in reality these are two hosts
roles and performance should be better with this approach.

[1]: https://docs.ovn.org/en/latest/intro/install/ovn-upgrades.html

Change-Id: I8f9dbe9d950323f16375ad5e1dbaedfb1be6585f
2022-11-28 13:52:30 +01:00
Ivan Halomi
652b9cfe0e Removal of dockerSDK check for other container engines
Typo fix and adding condition on not checking docker SDK version
when container engine is not docker

This is a followup to Ic30b67daa2e215524096ad1f4385c569e3d41b95
Signed-off-by: Ivan Halomi <i.halomi@partner.samsung.com>
Change-Id: Iafa24db06ad46bcfe250451ed98bc3c48d8a5138
2022-11-28 12:11:11 +00:00