Resolves: rhbz#1620043 rhbz#2019464 rhbz#2099653 rhbz#2109633 rhbz#2112293 rhbz#2116295 rhbz#2117600 rhbz#2117601

- Rebased to latest upstream sources (see CHANGELOG.md)
- Updated pcs-web-ui
This commit is contained in:
Michal Pospisil 2022-11-23 13:57:22 +01:00
parent 9455af1d47
commit 225917d4f4
5 changed files with 36 additions and 94 deletions

3
.gitignore vendored
View File

@ -179,3 +179,6 @@
/pcs-web-ui-0.1.15.tar.gz
/pcs-web-ui-node-modules-0.1.15.tar.xz
/rack-test-2.0.2.gem
/pcs-0.11.4.tar.gz
/pcs-web-ui-0.1.16.tar.gz
/pcs-web-ui-node-modules-0.1.16.tar.xz

View File

@ -1,4 +1,4 @@
From c4722151ae80e1848a89d4b830909ef18c906db3 Mon Sep 17 00:00:00 2001
From c7b8c999f796cee4899df578944b239e1db29cb5 Mon Sep 17 00:00:00 2001
From: Ivan Devat <idevat@redhat.com>
Date: Tue, 20 Nov 2018 15:03:56 +0100
Subject: [PATCH] do not support cluster setup with udp(u) transport in RHEL9
@ -9,7 +9,7 @@ Subject: [PATCH] do not support cluster setup with udp(u) transport in RHEL9
2 files changed, 3 insertions(+)
diff --git a/pcs/pcs.8.in b/pcs/pcs.8.in
index 363515bb..4c2496aa 100644
index 7bbd1ae2..53bfebb4 100644
--- a/pcs/pcs.8.in
+++ b/pcs/pcs.8.in
@@ -457,6 +457,8 @@ By default, encryption is enabled with cipher=aes256 and hash=sha256. To disable
@ -22,10 +22,10 @@ index 363515bb..4c2496aa 100644
.br
Transport options are: ip_version, netmtu
diff --git a/pcs/usage.py b/pcs/usage.py
index cfa2ac9c..519c853e 100644
index 073e2b1e..91ceb787 100644
--- a/pcs/usage.py
+++ b/pcs/usage.py
@@ -1429,6 +1429,7 @@ Commands:
@@ -1431,6 +1431,7 @@ Commands:
hash=sha256. To disable encryption, set cipher=none and hash=none.
Transports udp and udpu:
@ -34,5 +34,5 @@ index cfa2ac9c..519c853e 100644
support traffic encryption nor compression.
Transport options are:
--
2.37.3
2.38.1

View File

@ -1,31 +1,31 @@
Name: pcs
Version: 0.11.3
Release: 5%{?dist}
Version: 0.11.4
Release: 1%{?dist}
# https://docs.fedoraproject.org/en-US/packaging-guidelines/LicensingGuidelines/
# https://fedoraproject.org/wiki/Licensing:Main?rd=Licensing#Good_Licenses
# GPLv2: pcs
# ASL 2.0: tornado
# GPL-2.0-only: pcs
# Apache-2.0: tornado
# MIT: backports, childprocess, dacite, daemons, ethon, mustermann, rack,
# rack-protection, rack-test, sinatra, tilt
# GPLv2 or Ruby: eventmachne
# (GPLv2 or Ruby) and BSD: thin
# BSD or Ruby: ruby2_keywords, webrick
# BSD and MIT: ffi
License: GPLv2 and ASL 2.0 and MIT and BSD and (GPLv2 or Ruby) and (BSD or Ruby)
# GPL-2.0-only or Ruby: eventmachne
# (GPL-2.0-only or Ruby) and BSD: thin
# BSD-2-Clause or Ruby: ruby2_keywords, webrick
# BSD-3-Clause and MIT: ffi
License: GPL-2.0-only AND Apache-2.0 AND MIT AND BSD-3-Clause AND (GPL-2.0-only OR Ruby) AND (BSD-2-Clause OR Ruby)
URL: https://github.com/ClusterLabs/pcs
Group: System Environment/Base
Summary: Pacemaker Configuration System
#building only for architectures with pacemaker and corosync available
ExclusiveArch: i686 x86_64 s390x ppc64le aarch64
# %%global version_or_commit %%{version}
%global version_or_commit %{version}.185-6d88
%global version_or_commit %{version}
# %%global version_or_commit %%{version}.206-f51f
%global pcs_source_name %{name}-%{version_or_commit}
# ui_commit can be determined by hash, tag or branch
%global ui_commit 0.1.15
%global ui_modules_version 0.1.15
%global ui_commit 0.1.16
%global ui_modules_version 0.1.16
%global ui_src_name pcs-web-ui-%{ui_commit}
%global pcs_snmp_pkg_name pcs-snmp
@ -107,7 +107,6 @@ Source101: https://github.com/ClusterLabs/pcs-web-ui/releases/download/%{ui_comm
# pcs patches: <= 200
Patch1: do-not-support-cluster-setup-with-udp-u-transport.patch
Patch2: tests-properly-mock-os.kill-in-scheduler-deadlock.patch
# ui patches: >200
# Patch201: bzNUMBER-01-name.patch
@ -223,9 +222,9 @@ easily view, modify and create pacemaker based clusters.
Group: System Environment/Base
Summary: Pacemaker cluster SNMP agent
# https://fedoraproject.org/wiki/Licensing:Main?rd=Licensing#Good_Licenses
# GPLv2: pcs
# GPL-2.0-only: pcs
# BSD-2-Clause: pyagentx
License: GPLv2 and BSD-2-Clause
License: GPL-2.0-only and BSD-2-Clause
URL: https://github.com/ClusterLabs/pcs
# tar for unpacking pyagetx source tar ball
@ -292,7 +291,6 @@ update_times_patch(){
%autosetup -S git -n %{pcs_source_name} -N
%autopatch -p1 -M 200
update_times_patch %{PATCH1}
update_times_patch %{PATCH2}
# prepare dirs/files necessary for building all bundles
# -----------------------------------------------------
@ -326,7 +324,7 @@ cp -f %SOURCE44 rpm/
%define debug_package %{nil}
./autogen.sh
%{configure} --enable-local-build --enable-use-local-cache-only --enable-individual-bundling PYTHON=%{__python3} ruby_CFLAGS="%{optflags}" ruby_LIBS="%{build_ldflags}"
%{configure} --enable-local-build --enable-use-local-cache-only --enable-individual-bundling --enable-booth-enable-authfile-set --enable-booth-enable-authfile-unset PYTHON=%{__python3} ruby_CFLAGS="%{optflags}" ruby_LIBS="%{build_ldflags}"
make all
# build pcs-web-ui
@ -407,13 +405,10 @@ run_all_tests(){
# disabled tests:
#
# pcs_test.tier0.lib.commands.test_resource_agent.DescribeAgentUtf8.test_describe
# For an unknown reason this test is failing in mock environment and
# passing outside the mock environment.
# TODO: Investigate the issue
# pcs_test.tier0.daemon.app.test_app_remote.SyncConfigMutualExclusive
# disabled due to race conditions on slower machines
%{__python3} pcs_test/suite --tier0 -v --vanilla --all-but \
pcs_test.tier0.lib.commands.test_resource_agent.DescribeAgentUtf8.test_describe \
pcs_test.tier0.daemon.app.test_app_remote.SyncConfigMutualExclusive.test_get_not_locked \
pcs_test.tier0.daemon.app.test_app_remote.SyncConfigMutualExclusive.test_post_not_locked \
@ -435,7 +430,7 @@ run_all_tests(){
run_all_tests
%posttrans
# Make sure the new version of the daemon is runnning.
# Make sure the new version of the daemon is running.
# Also, make sure to start pcsd-ruby if it hasn't been started or even
# installed before. This is done by restarting pcsd.service.
%{_bindir}/systemctl daemon-reload
@ -528,6 +523,11 @@ run_all_tests
%license pyagentx_LICENSE.txt
%changelog
* Tue Nov 22 2022 Michal Pospisil <mpospisi@redhat.com> - 0.11.4-1
- Rebased to latest upstream sources (see CHANGELOG.md)
- Updated pcs-web-ui
- Resolves: rhbz#1620043 rhbz#2019464 rhbz#2099653 rhbz#2109633 rhbz#2112293 rhbz#2116295 rhbz#2117600 rhbz#2117601
* Mon Oct 24 2022 Miroslav Lisik <mlisik@redhat.com> - 0.11.3-5
- Rebased to latest upstream sources (see CHANGELOG.md)
- Updated pcs-web-ui

View File

@ -1,7 +1,6 @@
SHA512 (pyagentx-0.4.pcs.2.tar.gz) = d4194fec9a3e5fefe3793d49b7fec1feafef294c7e613a06046c2993daeefc5cb39d7c5b2b402ff83e49b2d976953f862264288c758c0be09d997b5323cc558a
SHA512 (eventmachine-1.2.7.gem) = fdbcf9fc933e2414e70f8f48153e9ba6ed7a0029cdf49cdcb4ab72ab26683e727a36c099f017f20681f9c361179461743e501278ca9bd5612e693e26867cc516
SHA512 (dacite-1.6.0.tar.gz) = 034255f095589d309fe5805413d8b148f430cd20a0de305b7954083b530d516da1d8f3f00ebb5264a8cfb77f2b2a76f1e2d863e78bd191f1d85021c5553815da
SHA512 (webrick-1.7.0.gem) = 5f242b50300046fe7c22ecd1640a73e5815e05a72bedfebe6bc39c24c92bd61abdd180860de0d194c0eebbc640b507b6892de181d3b577c5372ace0ca6faf2a3
SHA512 (backports-3.23.0.gem) = b6d721a2925a932e451437938e01c6e3f4ac08bafac975063963f7866e17015abfeb6862face89cbd08caf479db75eb085f540263ba251a87c6acc7611ba6d40
SHA512 (daemons-1.4.1.gem) = c057a7cbafc16f9daa073ce9fd5680f5f978826554073f4e77f2b284aee73567253d471224109d060193572f313e5eaa1509a2113a1564c1508969f658c045c5
SHA512 (ethon-0.15.0.gem) = 6e04c70e105fb95f1e0ff62e1d6ae009bb7b39a60d85ec9e43b10c016f33f679620ded253089a738e0cef5010e9023d1093dd92b1caacdde8f6a745cbae2b5b5
@ -9,13 +8,14 @@ SHA512 (ffi-1.15.5.gem) = 074df34edffc7038ab08199350a97b32280d61ea15dd85d459b008
SHA512 (ruby2_keywords-0.0.5.gem) = f6b9078b111e68c0017e0025ecdccb976c7a32f35c1a8adf9fd879db0c91f89eb9bd799f9527a846e28056f2a5fbf0f3610cda9538570288c493613c35c83a6f
SHA512 (thin-1.8.1.gem) = c200ea03b7876b2a17b5875557fa967b8d01db20cc401811f314f3285f8249b8793e4709b7bc033a9c5813b9a51e3093c55f717b4a98b8fda171aa82813b7419
SHA512 (rack-2.2.4.gem) = 7e7cd4f0e44e0cd7d26f35ca946a2b6fcee8ad73425583694a7ea9662816b39681325879ad84a2c0d31dbcc2ded1165b0a37d9278bf3d0b0f2bc4615b66b1ca2
SHA512 (pcs-0.11.3.185-6d88.tar.gz) = 4acfe67ee953bd7fc8b424b1433b0b55a5704b8370f4adb21a275c0d85011e799e5c8f87cf3b09b21af1de73c190934d0e09f6f0d23ad4bbcd3a27014db9f981
SHA512 (childprocess-4.1.0.gem) = e635c3acfa5ad85891c3879f240c7e96d47d7d5ec3f472f4ce6661552b0fb7bd72c5e3b9fb73f4f9312b749fbe554b4be388e56a31a3c63c39743d055d774def
SHA512 (mustermann-3.0.0.gem) = c33d41281fe2ac80c0af0c5c31dbab2068c73b9da19a4b82b387bbe551019fc115675634d932a8e56b070c3a06a85d830c982a103e6c5193aff8647f599be6e3
SHA512 (tilt-2.0.11.gem) = 757a292b05b3ddb2cb8de7680f09433cec85b433e03cd9f738534b99c836fb2129870003a9376c24b6a2f6acb732b51b27968cc0e197a832130d4a35b8dc8239
SHA512 (tornado-6.2.0.tar.gz) = b8f98b76198f21bb3a13f44e8698397d7906a415e75621550dfeea8ae3a7e9405f5e314136a93b6714455062501051c145dfd32c71b433715fc8ed591fcb882b
SHA512 (sinatra-3.0.2.gem) = 16638592dcfa4a0968e46bc6c6ce71c817ccaae050fe3d3d05d3f7dfcff86596c2586a821ba0968ae16755fed07a1655d608a9cd6546d90a1c2991099ef5e488
SHA512 (rack-protection-3.0.2.gem) = 54603e8ba22f1b359e5ffe82a3ee99a31a26e5dedd1e46edd4591ca416a1f241dc37ce2b6da25262a9cf9027b0e8687bd23c6dcbea0197131ca33088cbfd0280
SHA512 (pcs-web-ui-0.1.15.tar.gz) = 7a450efc2c83bd277a85417271d7a0176a1e5f2290c2ca169ff37032be96daec7ce59642dd50c26f8b6f2a3f9ead7f23d5a7a83a35e4b279acf519b45be7bdc5
SHA512 (pcs-web-ui-node-modules-0.1.15.tar.xz) = f2323821c15ba4f66179485517f8098a3ff46249c9609c3f2c2bb0ce6a9ddd73187c97c11e083cdb303dd71d2551e55cb5a937897824a7e4e9294b0f4137c293
SHA512 (rack-test-2.0.2.gem) = 1d395d9504f8d84bcf0e251a9c5873eace29f274b177c7a6bfbdce58f6085ab5170f66d16086e3e159aaa47480d5f993c77b64d613cefda342932c39ad37331d
SHA512 (pcs-web-ui-node-modules-0.1.16.tar.xz) = 2f94b49bdd7a01a01885cd2d48c5f8bc0338819a90851c404e951ea1aa343ab34f6dc0d4bf40a2cafd6c38bd766062f5577712b25761628e1772fae1e3a4c59f
SHA512 (webrick-1.7.0.gem) = 5f242b50300046fe7c22ecd1640a73e5815e05a72bedfebe6bc39c24c92bd61abdd180860de0d194c0eebbc640b507b6892de181d3b577c5372ace0ca6faf2a3
SHA512 (pcs-web-ui-0.1.16.tar.gz) = d0451df5fe8d1c3bd14df807f3eeae2e617c7498f52d3db67187553585fa019ba7fe7304e670f430943619f9bdca6b7c0f220d94c3b2423d8e75a1a374cde88c
SHA512 (pcs-0.11.4.tar.gz) = df5b7caab7c218676c92db7d8cb24135b3cee1b0aa947851f08659222d7be501e205438e49695339fbad8b14b5637d9cf790e14c9ccc5151e188345924dc0153

View File

@ -1,61 +0,0 @@
From 7d9285475e669e805483b50076a55a0ca617cf54 Mon Sep 17 00:00:00 2001
From: Ondrej Mular <omular@redhat.com>
Date: Tue, 25 Oct 2022 09:18:19 +0200
Subject: [PATCH] tests: properly mock os.kill in scheduler deadlock test
---
pcs_test/tier0/daemon/async_tasks/test_integration.py | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/pcs_test/tier0/daemon/async_tasks/test_integration.py b/pcs_test/tier0/daemon/async_tasks/test_integration.py
index 289da60f..a5ad801f 100644
--- a/pcs_test/tier0/daemon/async_tasks/test_integration.py
+++ b/pcs_test/tier0/daemon/async_tasks/test_integration.py
@@ -1,4 +1,5 @@
import dataclasses
+import signal
from datetime import timedelta
from logging import Logger
from multiprocessing import Process
@@ -507,6 +508,7 @@ class TaskResultsTests(MockOsKillMixin, IntegrationBaseTestCase):
self.assertEqual(RESULT, task_info.result)
+@mock.patch("pcs.daemon.async_tasks.task.os.kill")
class DeadlockTests(
MockOsKillMixin, AssertTaskStatesMixin, IntegrationBaseTestCase
):
@@ -526,7 +528,7 @@ class DeadlockTests(
).start()
@gen_test
- async def test_deadlock_mitigation(self):
+ async def test_deadlock_mitigation(self, mock_kill):
self._create_tasks(2)
self.execute_tasks(["id0"])
await self.perform_actions(1)
@@ -554,13 +556,15 @@ class DeadlockTests(
self.process_obj_mock.close.assert_not_called()
self.finish_tasks(["id1"])
self.process_obj_mock.is_alive.return_value = False
+ mock_kill.assert_not_called()
await self.perform_actions(1)
+ mock_kill.assert_called_once_with(1, signal.SIGCONT)
# tmp worker finished the task and terminated itself
self.assert_task_state_counts_equal(0, 0, 1, 1)
self.process_obj_mock.close.assert_called_once_with()
@gen_test
- async def test_max_worker_count_reached(self):
+ async def test_max_worker_count_reached(self, mock_kill):
self.scheduler._config = dataclasses.replace(
self.scheduler._config, max_worker_count=1
)
@@ -570,3 +574,4 @@ class DeadlockTests(
self.assert_task_state_counts_equal(0, 2, 1, 0)
self.process_cls_mock.assert_not_called()
self.process_obj_mock.assert_not_called()
+ mock_kill.assert_not_called()
--
2.37.3