From 004bcb38f4e640269e5cf0a1d829725dc77e58a249141aa41ac1a420696bbbe9 Mon Sep 17 00:00:00 2001 From: Alexandre Vicenzi Date: Mon, 5 Feb 2024 14:30:55 +0000 Subject: [PATCH] Accepting request 1144293 from home:avicenzi:branches:server:http RPM 4.19 updates OBS-URL: https://build.opensuse.org/request/show/1144293 OBS-URL: https://build.opensuse.org/package/show/server:http/caddy?expand=0&rev=41 --- caddy.changes | 6 ++++++ caddy.spec | 8 ++++++-- caddy.sysusers | 5 +++-- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/caddy.changes b/caddy.changes index 670cd23..fb3c621 100644 --- a/caddy.changes +++ b/caddy.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Feb 5 13:40:52 UTC 2024 - Alexandre Vicenzi + +- Provide user and group (due to RPM 4.19) +- Update caddy.sysusers to also create a group + ------------------------------------------------------------------- Fri Dec 08 02:07:42 UTC 2023 - Jeff Kowalczyk diff --git a/caddy.spec b/caddy.spec index c31abf4..e8b31c4 100644 --- a/caddy.spec +++ b/caddy.spec @@ -1,7 +1,7 @@ # # spec file for package caddy # -# Copyright (c) 2023 SUSE LLC +# Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,6 +17,8 @@ %define project github.com/caddyserver/caddy +%define gname caddy +%define uname caddy # SLE-12 _sharedstatedir was /usr/com, _localstatedir is /var as expected # SLE-15+ _sharedstatedir is /var/lib, _localstatedir is /var @@ -45,6 +47,8 @@ BuildRequires: golang-packaging BuildRequires: systemd-rpm-macros BuildRequires: sysuser-tools BuildRequires: golang(API) >= 1.20 +Provides: group(%{gname}) +Provides: user(%{uname}) %{?systemd_requires} %{sysusers_requires} %{go_provides} @@ -118,7 +122,7 @@ install -D -p -m 0644 %{SOURCE6} %{buildroot}%{_datadir}/zsh/site-functions/_%{n %{_sysusersdir}/%{name}.conf %dir %{_sysconfdir}/%{name} %config(noreplace) %{_sysconfdir}/%{name}/Caddyfile -%attr(0750,%{name},%{name}) %dir %{_sharedstatedir}/%{name} +%dir %attr(0750, %{uname}, %{gname}) %{_sharedstatedir}/%{name} # filesystem owns all the parent directories here %{_datadir}/bash-completion/completions/%{name} # own parent directories in case zsh is not installed diff --git a/caddy.sysusers b/caddy.sysusers index 9952eac..5f762c3 100644 --- a/caddy.sysusers +++ b/caddy.sysusers @@ -1,2 +1,3 @@ -# Type Name ID GECOS [HOME] -u caddy - "Caddy web server" /var/lib/caddy +#Type Name ID GECOS Home directory Shell +u caddy - "Caddy web server" /var/lib/caddy - +g caddy - - - -