public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Tobias Urdin <tobias.urdin@binero.com>
To: git-commits@fedoraproject.org
Subject: [rpms/rabbitmq-server] f44: [PATCH] Fix sysusers so rabbitmq user exists before installation
Date: Thu, 23 Jul 2026 09:58:50 GMT [thread overview]
Message-ID: <178480073074.1.15183036836171435543.rpms-rabbitmq-server-dd381575c04e@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/rabbitmq-server
Branch : f44
Commit : dd381575c04ea1e4c7b77c2253d221e03ad32231
Author : Tobias Urdin <tobias.urdin@binero.com>
Date : 2026-07-23T11:58:33+02:00
Stats : +12/-7 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/rabbitmq-server/c/dd381575c04ea1e4c7b77c2253d221e03ad32231?branch=f44
Log:
[PATCH] Fix sysusers so rabbitmq user exists before installation
Use systemd-rpm-macros %sysusers_create_package to generate
a preinstall scriptlet that runs systemd-sysusers early in
the RPM transaction.
This ensures the rabbitmq user/group exists before file
ownership is applied, removing "using root" warnings during
install.
---
diff --git a/rabbitmq-server.spec b/rabbitmq-server.spec
index ef83b07..cefe3b2 100644
--- a/rabbitmq-server.spec
+++ b/rabbitmq-server.spec
@@ -8,7 +8,7 @@
Name: rabbitmq-server
Version: 4.2.9
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: The RabbitMQ server
License: MPL-2.0
Source0: https://github.com/rabbitmq/rabbitmq-server/releases/download/v%{version}/%{name}_%{version}.orig.tar.xz
@@ -19,6 +19,7 @@ Source3: rabbitmq-server.logrotate
# curl -O https://raw.githubusercontent.com/rabbitmq/rabbitmq-server-release/rabbitmq_v3_6_16/packaging/RPMS/Fedora/rabbitmq-server.tmpfiles
Source5: rabbitmq-server.tmpfiles
Source6: rabbitmq-server-cuttlefish
+Source7: rabbitmq-server.sysusers.conf
Patch: rabbitmq-server-0001-Use-default-EPMD-socket.patch
Patch: rabbitmq-server-0002-Use-proto_dist-from-command-line.patch
Patch: rabbitmq-server-0003-force-python3.patch
@@ -37,6 +38,7 @@ BuildRequires: make
BuildRequires: python3
BuildRequires: rsync
BuildRequires: systemd
+BuildRequires: systemd-rpm-macros
BuildRequires: xmlto
BuildRequires: zip
Requires: erlang-eldap%{?_isa} >= %{erlang_minver}
@@ -67,11 +69,6 @@ scalable implementation of an AMQP broker.
%{gpgverify} --keyring='%{SOURCE2}' --signature='%{SOURCE1}' --data='%{SOURCE0}'
%autosetup -p1
-# Create a sysusers.d config file
-cat >rabbitmq-server.sysusers.conf <<EOF
-u rabbitmq - 'RabbitMQ messaging server' %{_localstatedir}/lib/rabbitmq -
-EOF
-
%build
make PROJECT_VERSION=%{version} ESCRIPT_ZIP="zip -9 -X" V=1 # Doesn't support %%{?_smp_mflags}
@@ -120,13 +117,17 @@ install -p -D -m 0644 ./deps/rabbit/docs/rabbitmq.conf.example %{buildroot}%{_sy
install -d %{buildroot}%{_localstatedir}/run/rabbitmq
install -p -D -m 0644 %{SOURCE5} %{buildroot}%{_prefix}/lib/tmpfiles.d/%{name}.conf
-install -m0644 -D rabbitmq-server.sysusers.conf %{buildroot}%{_sysusersdir}/rabbitmq-server.conf
+install -m0644 -D %{SOURCE7} %{buildroot}%{_sysusersdir}/rabbitmq-server.conf
%check
#make check
+%pre
+%sysusers_create_package %{name} %{SOURCE7}
+
+
%post
%systemd_post %{name}.service
@@ -177,6 +178,9 @@ rm -f %{_rabbit_libdir}/lib/rabbitmq_server-%{version}/ebin/rabbit.{rel,script,b
%changelog
+* Fri Jul 23 2026 Tobias Urdin <tobias.urdin@binero.com> - 4.2.9-2
+- Fix sysusers
+
* Wed Jul 22 2026 Peter Lemenkov <lemenkov@gmail.com> - 4.2.9-1
- Ver. 4.2.9
diff --git a/rabbitmq-server.sysusers.conf b/rabbitmq-server.sysusers.conf
new file mode 100644
index 0000000..c7eff1e
--- /dev/null
+++ b/rabbitmq-server.sysusers.conf
@@ -0,0 +1 @@
+u rabbitmq - 'RabbitMQ messaging server' /var/lib/rabbitmq -
reply other threads:[~2026-07-23 9:58 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=178480073074.1.15183036836171435543.rpms-rabbitmq-server-dd381575c04e@fedoraproject.org \
--to=tobias.urdin@binero.com \
--cc=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox