From 21be3e002782c0cd24ecbc9944fc953498bc73a0 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Mon, 22 Jan 2024 11:20:52 +0000 Subject: [PATCH 01/21] Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild --- resalloc.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resalloc.spec b/resalloc.spec index bcfcbcd..4073678 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -39,7 +39,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling Version: 5.1 -Release: 1%{?dist} +Release: 2%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -345,6 +345,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Mon Jan 22 2024 Fedora Release Engineering - 5.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + * Mon Nov 06 2023 Pavel Raiskup - 5.1-1 - new upstream release https://github.com/praiskup/resalloc/releases/tag/v5.1 From d54e87f453b0cc35b3b27074efb7862de0d064a2 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 26 Jan 2024 15:12:04 +0000 Subject: [PATCH 02/21] Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild --- resalloc.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resalloc.spec b/resalloc.spec index 4073678..b3956cb 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -39,7 +39,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling Version: 5.1 -Release: 2%{?dist} +Release: 3%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -345,6 +345,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Fri Jan 26 2024 Fedora Release Engineering - 5.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + * Mon Jan 22 2024 Fedora Release Engineering - 5.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild From 2c449aed0c291d6b883db20c543f7631eff0dafb Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Wed, 28 Feb 2024 08:32:11 +0100 Subject: [PATCH 03/21] New upstream release Version: 5.2-1 --- resalloc.spec | 17 +++++- sources | 2 +- wait-for-ssh | 161 ++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 177 insertions(+), 3 deletions(-) create mode 100644 wait-for-ssh diff --git a/resalloc.spec b/resalloc.spec index b3956cb..6eb9e6b 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -38,8 +38,8 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.1 -Release: 3%{?dist} +Version: 5.2 +Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -88,6 +88,8 @@ Source5: resalloc-agent-spawner.service Source2: logrotate Source3: merge-hook-logs Source4: cron.hourly +# GPL-2.0-or-later too +Source6: https://raw.githubusercontent.com/praiskup/wait-for-ssh/main/wait-for-ssh %description %desc @@ -144,6 +146,9 @@ Summary: %sum - daemon starting agent-like resources Requires(pre): /usr/sbin/useradd Requires: python3-copr-common +Requires: python3-daemon +Requires: python3-redis +Requires: python3-setproctitle %description agent-spawner %desc @@ -204,10 +209,13 @@ rm -r resalloc_agent_spawner %build %if %{with python2} +python=%__python2 %py2_build %else %py3_build +python=%__python3 %endif +sed "1c#! $python" %SOURCE6 > %{name}-wait-for-ssh %install @@ -238,6 +246,7 @@ install -d -m 755 %buildroot/%_libexecdir install -p -m 755 %SOURCE3 %buildroot/%_libexecdir/%name-merge-hook-logs install -d %buildroot%_sysconfdir/cron.hourly install -p -m 755 %SOURCE4 %buildroot%_sysconfdir/cron.hourly/resalloc +install -p -m 755 %name-wait-for-ssh %buildroot%_bindir/%name-wait-for-ssh %if %{without python3} rm %buildroot%_bindir/%name-agent-* @@ -315,6 +324,7 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %{_bindir}/%{name}-server %{_bindir}/%{name}-maint %{_bindir}/%{name}-check-vm-ip +%{_bindir}/%{name}-wait-for-ssh %attr(0750, %sysuser, %sysgroup) %dir %{_sysconfdir}/%{name}server %config(noreplace) %{_sysconfdir}/%{name}server/* %_unitdir/resalloc.service @@ -345,6 +355,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Wed Feb 28 2024 Pavel Raiskup - 5.2-1 +- New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.2 + * Fri Jan 26 2024 Fedora Release Engineering - 5.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild diff --git a/sources b/sources index 281955a..045cf41 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.1.tar.gz) = 2ce355ecec7441d2b4f589f6e152422a316fa6dda8c0d737c29f8d12d6627b240ff3e46fa04e9664882228cc11b94c03f0d4fca25064e8e1c6848ec3fce11946 +SHA512 (resalloc-5.2.tar.gz) = c3df15356865d6db5514a8b936c2848c90e54f21379e267a4e286be8cd9cb4c477378c14b0d45ed4755334b541aa0b2e1c640b38f054cb3d997fe0ec0229a71d diff --git a/wait-for-ssh b/wait-for-ssh new file mode 100644 index 0000000..d302c77 --- /dev/null +++ b/wait-for-ssh @@ -0,0 +1,161 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +# Copyright (C) 2017 Pavel Raiskup +# +# This program accepts one argument IP or HOSTNAME. First try to connect to the +# HOSTNAME as 'root' user. If cloud-init scripts instruct us to use different +# user than 'root', switch to that user and check again. In the end, print the +# successful username on stdout. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License along +# with this program; if not, write to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +from re import compile as re_compile +import sys +from os import devnull +from threading import Thread, Event +from argparse import ArgumentParser +from subprocess import Popen, PIPE +import logging + +handler = logging.StreamHandler() +log = logging.getLogger() +log.setLevel(logging.INFO) +log.addHandler(handler) + +# create console handler and set level to debug + +ssh = [ + 'ssh', + '-o', 'StrictHostKeyChecking=no', + '-o', 'UserKnownHostsFile=/dev/null', + '-o', 'PasswordAuthentication=no', + '-o', 'ConnectTimeout=10', +] + +expected_output = 'foobar' +inner_cmd = 'echo ' + expected_output + + +class Checker(Thread): + user = 'root' + daemon = True + user_re = '[a-zA-Z0-9_.][a-zA-Z0-9_.-]*[$]?' + re_clouduser = re_compile('Please login as the user "({0})"'.format(user_re)) + event = Event() + + def loop(self): + cmd = ssh + [ + '{0}@{1}'.format(self.user, self.args.host), + inner_cmd, + ] + + with open(devnull, 'w') as drop: + log.debug('executing: ' + ' '.join(cmd)) + self.child = Popen(cmd, stdout=PIPE, stderr=drop) + (stdout, _) = self.child.communicate() + + exp = (expected_output + '\n').encode('ascii') + if self.child.returncode == 0 and stdout == exp: + if self.args.print_user: + print(self.user) + return True + + if self.args.cloud_user: + match = self.re_clouduser.search(str(stdout)) + if match: + self.user = match.group(1) + log.info('cloud user switched to ' + self.user) + return False + + def run(self): + while True: + if self.loop(): + # Success! + break + + if self.event.wait(1): + log.debug("stopping per kill event") + break + + def kill(self): + self.event.set() + + # Best effort kill. + try: + self.child.kill() + except: + pass + self.join() + + +parser = ArgumentParser( + description="Wait till the host's ssh becomes responsive.") +parser.add_argument('host', help='hostname or IP') +parser.add_argument('--timeout', + help='seconds to wait before failure, default=indefinitely', + default=None, type=float) +parser.add_argument('--check-cloud-user', action='store_true', default=False, + dest='cloud_user', + help='if cloud-init disallows "root" login, try to detect the cloud ' \ + +'user and use that') +parser.add_argument('--print-user', action='store_true', default=False, + dest='print_user', + help='print the username which succeeded to connect on stdout') +parser.add_argument('--log', default=False, + dest='log_verbosity', + help='set the threshold for logging, e.g. debug, info, error, ...') + + +def main(): + sleep_period = 1.0 + args = parser.parse_args() + + if args.log_verbosity: + log.setLevel(logging.getLevelName(args.log_verbosity.upper())) + + def timeouted(): + if args.timeout is None: + return False + log.debug("wait {0}s, remains {1}s".format(sleep_period, args.timeout)) + args.timeout -= sleep_period + return args.timeout <= 0 + + checker = Checker() + checker.args = args + checker.start() + + try: + # threading.join() is not Ctrl-C interruptable :( in python2, so we need + # this ugly infinite loop. + # https://stackoverflow.com/questions/25676835/signal-handling-in-multi-threaded-python + while True: + checker.join(sleep_period) + if not checker.is_alive(): + # Success! + return 0 + + if timeouted(): + log.error("timeout!") + checker.kill() + return 1 + + except KeyboardInterrupt: + log.error("interrupt by user") + checker.kill() + return 1 + +if __name__ == "__main__": + sys.exit(main()) From 388f5e356bb2dceecd104ca4907ee1b2f7877f28 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Wed, 28 Feb 2024 08:35:53 +0100 Subject: [PATCH 04/21] Build for F40 --- build-and-update-all-branches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-and-update-all-branches b/build-and-update-all-branches index aefeec9..e93f5d8 100755 --- a/build-and-update-all-branches +++ b/build-and-update-all-branches @@ -3,7 +3,7 @@ # Prepare main branch, review the list of branches below and then execute this # script. -branches='main f39 f38 f37 epel7 epel8 epel9' +branches='main f40 f39 f38 epel7 epel8 epel9' exit_handler () { From 11c0cf61ca4c73eb159b3dc3265a7308bbb59dc3 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Wed, 28 Feb 2024 09:02:24 +0100 Subject: [PATCH 05/21] New upstream release Version: 5.3-1 --- resalloc.spec | 27 ++++++++++++++++++++++++--- sources | 2 +- 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/resalloc.spec b/resalloc.spec index 6eb9e6b..1258902 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -38,7 +38,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.2 +Version: 5.3 Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc @@ -103,6 +103,7 @@ Summary: %sum - server part Requires: crontabs Requires: logrotate Requires: %default_python-%srcname = %version-%release +Requires: %srcname-helpers = %version-%release %if %{with python3} Requires: python3-alembic Requires: python3-six @@ -122,6 +123,17 @@ Requires(pre): /usr/sbin/useradd The %name-server package provides the resalloc server, and some tooling for resalloc administrators. + +%package helpers +Summary: %sum - helper/library scripts + +%description helpers +%desc + +Helper and library-like scripts for external Resalloc plugins like resalloc-aws, +resalloc-openstack, etc. + + %if %{with python3} %package webui Summary: %sum - webui part @@ -323,8 +335,6 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %{default_sitelib}/%{name}server %{_bindir}/%{name}-server %{_bindir}/%{name}-maint -%{_bindir}/%{name}-check-vm-ip -%{_bindir}/%{name}-wait-for-ssh %attr(0750, %sysuser, %sysgroup) %dir %{_sysconfdir}/%{name}server %config(noreplace) %{_sysconfdir}/%{name}server/* %_unitdir/resalloc.service @@ -336,6 +346,14 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %_libexecdir/resalloc-merge-hook-logs %config %attr(0755, root, root) %{_sysconfdir}/cron.hourly/resalloc + +%files helpers +%doc %doc_files +%license COPYING +%{_bindir}/%{name}-check-vm-ip +%{_bindir}/%{name}-wait-for-ssh + + %if %{with python3} %files agent-spawner %_bindir/resalloc-agent* @@ -355,6 +373,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Wed Feb 28 2024 Pavel Raiskup - 5.3-1 +- New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.3 + * Wed Feb 28 2024 Pavel Raiskup - 5.2-1 - New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.2 diff --git a/sources b/sources index 045cf41..56b8ef9 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.2.tar.gz) = c3df15356865d6db5514a8b936c2848c90e54f21379e267a4e286be8cd9cb4c477378c14b0d45ed4755334b541aa0b2e1c640b38f054cb3d997fe0ec0229a71d +SHA512 (resalloc-5.3.tar.gz) = 4bb4c087567edfc4b33b4e6537ce078217aba2dbd1705a6c894029460f847f1bb890e5d78fec8da3e8d4147f8b8849cf84130d7f23cb3a3f277ae00e85cf84e5 From 7d5694c44fe029afed34a061a3e2829a149021b4 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Fri, 15 Mar 2024 15:51:24 +0100 Subject: [PATCH 06/21] New upstream release Version: 5.4-1 --- resalloc.spec | 8 ++++++-- sources | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/resalloc.spec b/resalloc.spec index 1258902..e3a3d08 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -38,7 +38,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.3 +Version: 5.4 Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc @@ -157,9 +157,10 @@ it shows page with information about resalloc resources. Summary: %sum - daemon starting agent-like resources Requires(pre): /usr/sbin/useradd -Requires: python3-copr-common +Requires: python3-copr-common >= 0.23 Requires: python3-daemon Requires: python3-redis +Requires: python3-resalloc = %version-%release Requires: python3-setproctitle %description agent-spawner @@ -373,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Fri Mar 15 2024 Pavel Raiskup - 5.4-1 +- New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.4 + * Wed Feb 28 2024 Pavel Raiskup - 5.3-1 - New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.3 diff --git a/sources b/sources index 56b8ef9..363ae44 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.3.tar.gz) = 4bb4c087567edfc4b33b4e6537ce078217aba2dbd1705a6c894029460f847f1bb890e5d78fec8da3e8d4147f8b8849cf84130d7f23cb3a3f277ae00e85cf84e5 +SHA512 (resalloc-5.4.tar.gz) = b827c8bd80c4813582ea499d74db406017d3be99f32f3db97a4f41a560bc1e96f3c19ba78a32ac498a2900ecca8ad4caa5d2bded359031e600d6f0ff704c5290 From 4c5ff134978df7095e3951fef34169dc00592285 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Wed, 24 Apr 2024 11:05:33 +0200 Subject: [PATCH 07/21] New upstream release Version: 5.5-1 --- resalloc.spec | 5 ++++- sources | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/resalloc.spec b/resalloc.spec index e3a3d08..db45191 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -38,7 +38,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.4 +Version: 5.5 Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc @@ -374,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Wed Apr 24 2024 Pavel Raiskup - 5.5-1 +- New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.5 + * Fri Mar 15 2024 Pavel Raiskup - 5.4-1 - New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.4 diff --git a/sources b/sources index 363ae44..30218a2 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.4.tar.gz) = b827c8bd80c4813582ea499d74db406017d3be99f32f3db97a4f41a560bc1e96f3c19ba78a32ac498a2900ecca8ad4caa5d2bded359031e600d6f0ff704c5290 +SHA512 (resalloc-5.5.tar.gz) = d555ab49825a238d6e06ab8feadb3dbac6bae5bede3b38aedcbf433001b9c9a2dfd27f6fadab7d3c9471ff1996e60e6a5124ef2da1ec51bf5d525244e30b71c7 From ec0b2a774b2deb67fd74236b0dd47c20c0e3767a Mon Sep 17 00:00:00 2001 From: Python Maint Date: Sun, 9 Jun 2024 17:13:14 +0200 Subject: [PATCH 08/21] Rebuilt for Python 3.13 --- resalloc.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resalloc.spec b/resalloc.spec index db45191..77a7722 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -39,7 +39,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling Version: 5.5 -Release: 1%{?dist} +Release: 2%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -374,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Sun Jun 09 2024 Python Maint - 5.5-2 +- Rebuilt for Python 3.13 + * Wed Apr 24 2024 Pavel Raiskup - 5.5-1 - New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.5 From d182f79e3d5569e048e1201562f2c1b22f96d0d0 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 19 Jul 2024 18:30:01 +0000 Subject: [PATCH 09/21] Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild --- resalloc.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resalloc.spec b/resalloc.spec index 77a7722..127a014 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -39,7 +39,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling Version: 5.5 -Release: 2%{?dist} +Release: 3%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -374,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Fri Jul 19 2024 Fedora Release Engineering - 5.5-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild + * Sun Jun 09 2024 Python Maint - 5.5-2 - Rebuilt for Python 3.13 From 7261b0d62e8f98cb0bc40f2aacb17d987bdf5fe9 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Mon, 7 Oct 2024 09:10:58 +0200 Subject: [PATCH 10/21] New upstream release Version: 5.6-1 --- build-and-update-all-branches | 2 +- resalloc.spec | 7 +++++-- sources | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/build-and-update-all-branches b/build-and-update-all-branches index e93f5d8..04b3544 100755 --- a/build-and-update-all-branches +++ b/build-and-update-all-branches @@ -3,7 +3,7 @@ # Prepare main branch, review the list of branches below and then execute this # script. -branches='main f40 f39 f38 epel7 epel8 epel9' +branches='main f41 f40 f39 epel8 epel9' exit_handler () { diff --git a/resalloc.spec b/resalloc.spec index 127a014..5abde19 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -38,8 +38,8 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.5 -Release: 3%{?dist} +Version: 5.6 +Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -374,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Mon Oct 07 2024 Pavel Raiskup - 5.6-1 +- New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.6 + * Fri Jul 19 2024 Fedora Release Engineering - 5.5-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild diff --git a/sources b/sources index 30218a2..1911cc5 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.5.tar.gz) = d555ab49825a238d6e06ab8feadb3dbac6bae5bede3b38aedcbf433001b9c9a2dfd27f6fadab7d3c9471ff1996e60e6a5124ef2da1ec51bf5d525244e30b71c7 +SHA512 (resalloc-5.6.tar.gz) = af8e5bff3a824d7d643e5c4c253f4f64f8eb3dfb7927e48f27be10cb91ad1a5b6571d5d2831d05d6a3e648160b34664b703883b2c27035086e54800418f9ef4c From 03060a1dee246c7b966336304fa0bb188bdc73b9 Mon Sep 17 00:00:00 2001 From: Jakub Kadlcik Date: Fri, 10 Jan 2025 12:42:28 +0100 Subject: [PATCH 11/21] New upstream release --- resalloc.spec | 5 ++++- sources | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/resalloc.spec b/resalloc.spec index 5abde19..2c2598d 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -38,7 +38,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.6 +Version: 5.7 Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc @@ -374,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Fri Jan 10 2025 Jakub Kadlcik - 5.7-1 +- New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.7 + * Mon Oct 07 2024 Pavel Raiskup - 5.6-1 - New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.6 diff --git a/sources b/sources index 1911cc5..51ce83a 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.6.tar.gz) = af8e5bff3a824d7d643e5c4c253f4f64f8eb3dfb7927e48f27be10cb91ad1a5b6571d5d2831d05d6a3e648160b34664b703883b2c27035086e54800418f9ef4c +SHA512 (resalloc-5.7.tar.gz) = fa4c52d149f770e88016771c560020d3355c9ae71d424533ce3e364c66f6a7b7e3cfdd844541455a782166e244a39f2b0fa0b5b3e8a9310299525efb107c2150 From 6ff47bc8eab705c0f66e468b8a96b94cd71a6b31 Mon Sep 17 00:00:00 2001 From: Jakub Kadlcik Date: Thu, 16 Jan 2025 14:00:44 +0100 Subject: [PATCH 12/21] New upstream release --- resalloc.spec | 5 ++++- sources | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/resalloc.spec b/resalloc.spec index 2c2598d..30c0d9a 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -38,7 +38,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.7 +Version: 5.8 Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc @@ -374,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Thu Jan 16 2025 Jakub Kadlcik - 5.8-1 +- New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.8 + * Fri Jan 10 2025 Jakub Kadlcik - 5.7-1 - New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.7 diff --git a/sources b/sources index 51ce83a..c8e1abe 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.7.tar.gz) = fa4c52d149f770e88016771c560020d3355c9ae71d424533ce3e364c66f6a7b7e3cfdd844541455a782166e244a39f2b0fa0b5b3e8a9310299525efb107c2150 +SHA512 (resalloc-5.8.tar.gz) = 9d24465a20978e9b461f90861af92f56d10cc80a5653e9a688a4b24d3dfac2caf0259fd3d0004b6cfeb367aea7a07bedc02ab4f06efab57a6aff5d280641ba68 From 6bfef927deaacb4a41e149daf2695814bcfcd1a1 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Sat, 18 Jan 2025 20:57:59 +0100 Subject: [PATCH 13/21] New upstream release Version: 5.9-1 --- resalloc.spec | 5 ++++- sources | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/resalloc.spec b/resalloc.spec index 30c0d9a..fe9bf5c 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -38,7 +38,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.8 +Version: 5.9 Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc @@ -374,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Sat Jan 18 2025 Pavel Raiskup - 5.9-1 +- New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.9 + * Thu Jan 16 2025 Jakub Kadlcik - 5.8-1 - New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.8 diff --git a/sources b/sources index c8e1abe..21c360d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.8.tar.gz) = 9d24465a20978e9b461f90861af92f56d10cc80a5653e9a688a4b24d3dfac2caf0259fd3d0004b6cfeb367aea7a07bedc02ab4f06efab57a6aff5d280641ba68 +SHA512 (resalloc-5.9.tar.gz) = 270c7a5d080fd8a2bfaddafb6f220e3749e70367494f6e10861bebf1c5a8f93d965ec1393b3baec1037591dec15a1769a4d29132b1f340259fa60e4d8143d4dc From d80af559156bf4664ed7d87eecc46b08219c0e57 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Sat, 18 Jan 2025 21:01:30 +0100 Subject: [PATCH 14/21] releng: no more f39 releases --- build-and-update-all-branches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-and-update-all-branches b/build-and-update-all-branches index 04b3544..502bf7c 100755 --- a/build-and-update-all-branches +++ b/build-and-update-all-branches @@ -3,7 +3,7 @@ # Prepare main branch, review the list of branches below and then execute this # script. -branches='main f41 f40 f39 epel8 epel9' +branches='main f41 f40 epel8 epel9' exit_handler () { From 0e203a5774b20b24d946d16ef42f58a7f8378d8c Mon Sep 17 00:00:00 2001 From: Python Maint Date: Thu, 5 Jun 2025 08:12:25 +0200 Subject: [PATCH 15/21] Rebuilt for Python 3.14 --- resalloc.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resalloc.spec b/resalloc.spec index fe9bf5c..5320ed1 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -39,7 +39,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling Version: 5.9 -Release: 1%{?dist} +Release: 2%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -374,6 +374,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Thu Jun 05 2025 Python Maint - 5.9-2 +- Rebuilt for Python 3.14 + * Sat Jan 18 2025 Pavel Raiskup - 5.9-1 - New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.9 From 2758a259369820be91c3ce342af42289ffb71034 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Thu, 12 Jun 2025 13:12:32 +0200 Subject: [PATCH 16/21] New upstream release Version: 5.10-1 --- build-and-update-all-branches | 20 +++++++--------- resalloc.spec | 45 +++++++++++++++++++++++++++++++---- sources | 2 +- 3 files changed, 51 insertions(+), 16 deletions(-) diff --git a/build-and-update-all-branches b/build-and-update-all-branches index 502bf7c..9d7b6da 100755 --- a/build-and-update-all-branches +++ b/build-and-update-all-branches @@ -1,13 +1,14 @@ #! /bin/sh -# Prepare main branch, review the list of branches below and then execute this +# Prepare rawhide branch, review the list of branches below and then execute this # script. -branches='main f41 f40 epel8 epel9' +main=main +branches="$main epel8 epel9 f41 f42" exit_handler () { - git checkout main + git checkout $main } trap exit_handler EXIT @@ -19,21 +20,18 @@ koji hello tasks= for branch in $branches; do - if test $branch != main; then + if test $branch != $main; then git checkout "$branch" - git merge main + git merge $main fi git push - skip_nvr_check= - if test $branch = epel7; then - skip_nvr_check=--skip-nvr-check - fi - tasks="${tasks}`fedpkg build $skip_nvr_check --nowait | grep 'Created task' | cut -d: -f2`" + tasks="${tasks}`fedpkg build --nowait | grep 'Created task' | cut -d: -f2`" done if test -n "$tasks"; then koji watch-task $tasks fi -git checkout main +set -- $branches +git checkout $1 fedpkg update diff --git a/resalloc.spec b/resalloc.spec index 5320ed1..7ddaa30 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -33,13 +33,25 @@ the purposes of CI/CD tasks. %bcond_with python3 %endif +# Modern distributions (using RPM v4.19+; for example, Fedora 39+) do not +# require the %%pre scriptlet for creating users/groups because the sysusers +# feature is now built directly into RPM. Simply including the sysusers +# `mock.conf` file in a package payload is sufficient to leverage this feature. +# However, for older distributions that lack this capability, we still define +# the %%pre scriptlet. +%if (0%{?rhel} && 0%{?rhel} < 10) || (0%{?mageia} && 0%{?mageia} < 10) || (0%{?suse_version} && 0%{?suse_version} < 1660) +%bcond_without sysusers_compat +%else +%bcond_with sysusers_compat +%endif + %global default_python %{?with_python3:python3}%{!?with_python3:python2} %global default_sitelib %{?with_python3:%python3_sitelib}%{!?with_python3:%python_sitelib} Name: %srcname Summary: %sum - client tooling -Version: 5.9 -Release: 2%{?dist} +Version: 5.10 +Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -82,6 +94,10 @@ BuildRequires: python-yaml Requires: %default_python-%srcname = %version-%release +%if %{with sysusers_compat} +Requires(pre): shadow-utils +%endif + Source0: https://github.com/praiskup/%name/releases/download/v%version/%name-%version.tar.gz Source1: resalloc.service Source5: resalloc-agent-spawner.service @@ -116,7 +132,6 @@ Requires: python-sqlalchemy Requires: python-yaml %endif -Requires(pre): /usr/sbin/useradd %description server %desc @@ -156,7 +171,6 @@ it shows page with information about resalloc resources. %package agent-spawner Summary: %sum - daemon starting agent-like resources -Requires(pre): /usr/sbin/useradd Requires: python3-copr-common >= 0.23 Requires: python3-daemon Requires: python3-redis @@ -219,6 +233,16 @@ restorecon -R %_var/www/cgi-%{name} || : rm -r resalloc_agent_spawner %endif +# Create sysusers.d config files +cat >resalloc.sysusers.conf <resalloc-agent-spawner.sysusers.conf < - 5.10-1 +- new upstream release, packages use RPM built-in sysusers support: + https://github.com/praiskup/resalloc/releases/tag/v5.10 + * Thu Jun 05 2025 Python Maint - 5.9-2 - Rebuilt for Python 3.14 diff --git a/sources b/sources index 21c360d..8e39ac1 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.9.tar.gz) = 270c7a5d080fd8a2bfaddafb6f220e3749e70367494f6e10861bebf1c5a8f93d965ec1393b3baec1037591dec15a1769a4d29132b1f340259fa60e4d8143d4dc +SHA512 (resalloc-5.10.tar.gz) = a8116bd663ffe75c5322c929dd0609569dfe6a0e8efe6c9fdebcd81882d99f6c077fb6a0b260ceae074f4994eb86d9c93a9f22b68251c39e7b8e29c4c5797e34 From e065fd3c642144f3a36a806059d8312a1a8ec58b Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Mon, 21 Jul 2025 15:29:22 +0200 Subject: [PATCH 17/21] New upstream release https://github.com/praiskup/resalloc/releases/tag/v5.11 --- resalloc.spec | 2 +- sources | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resalloc.spec b/resalloc.spec index 7ddaa30..96a3adf 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -50,7 +50,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling -Version: 5.10 +Version: 5.11 Release: 1%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc diff --git a/sources b/sources index 8e39ac1..f458908 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (resalloc-5.10.tar.gz) = a8116bd663ffe75c5322c929dd0609569dfe6a0e8efe6c9fdebcd81882d99f6c077fb6a0b260ceae074f4994eb86d9c93a9f22b68251c39e7b8e29c4c5797e34 +SHA512 (resalloc-5.11.tar.gz) = 73becebe671a59912006eb4b227c10f6ac7be91a91e94cff470ac6bb32eb4447ec905b1d151c5eeb54fdc6c2a6179f9b7d606bcf25c3f9caeb63bde171759ac3 From 6c799be7e51a3f460a5f80bbc9e35543841be095 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Mon, 21 Jul 2025 15:37:35 +0200 Subject: [PATCH 18/21] Forgotten changelog entry --- resalloc.spec | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/resalloc.spec b/resalloc.spec index 96a3adf..5d19b70 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -407,6 +407,10 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Mon Jul 21 2025 Pavel Raiskup - 5.11-1 +- new upstream release, don't keep cleanup processes indefinitely: + https://github.com/praiskup/resalloc/releases/tag/v5.11 + * Thu Jun 12 2025 Pavel Raiskup - 5.10-1 - new upstream release, packages use RPM built-in sysusers support: https://github.com/praiskup/resalloc/releases/tag/v5.10 From 9b7713aa1fd75a29b8b8ef1a30fcf156ffa6384a Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 25 Jul 2025 11:54:41 +0000 Subject: [PATCH 19/21] Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild --- resalloc.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resalloc.spec b/resalloc.spec index 5d19b70..9810bb0 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -51,7 +51,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling Version: 5.11 -Release: 1%{?dist} +Release: 2%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -407,6 +407,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Fri Jul 25 2025 Fedora Release Engineering - 5.11-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + * Mon Jul 21 2025 Pavel Raiskup - 5.11-1 - new upstream release, don't keep cleanup processes indefinitely: https://github.com/praiskup/resalloc/releases/tag/v5.11 From bd93fdb44c6ca9449c56f1b3eb27977a83024246 Mon Sep 17 00:00:00 2001 From: Python Maint Date: Fri, 15 Aug 2025 15:15:37 +0200 Subject: [PATCH 20/21] Rebuilt for Python 3.14.0rc2 bytecode --- resalloc.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resalloc.spec b/resalloc.spec index 9810bb0..ff5c4d2 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -51,7 +51,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling Version: 5.11 -Release: 2%{?dist} +Release: 3%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -407,6 +407,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Fri Aug 15 2025 Python Maint - 5.11-3 +- Rebuilt for Python 3.14.0rc2 bytecode + * Fri Jul 25 2025 Fedora Release Engineering - 5.11-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild From c46cbb5e81d436341d773ca988012b89851380cb Mon Sep 17 00:00:00 2001 From: Python Maint Date: Fri, 19 Sep 2025 14:53:02 +0200 Subject: [PATCH 21/21] Rebuilt for Python 3.14.0rc3 bytecode --- resalloc.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resalloc.spec b/resalloc.spec index ff5c4d2..7093616 100644 --- a/resalloc.spec +++ b/resalloc.spec @@ -51,7 +51,7 @@ the purposes of CI/CD tasks. Name: %srcname Summary: %sum - client tooling Version: 5.11 -Release: 3%{?dist} +Release: 4%{?dist} License: GPL-2.0-or-later URL: https://github.com/praiskup/resalloc BuildArch: noarch @@ -407,6 +407,9 @@ ln -s "%{default_sitelib}/%{name}server" %buildroot%_homedir/project %changelog +* Fri Sep 19 2025 Python Maint - 5.11-4 +- Rebuilt for Python 3.14.0rc3 bytecode + * Fri Aug 15 2025 Python Maint - 5.11-3 - Rebuilt for Python 3.14.0rc2 bytecode