public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Jan-Frode Myklebust <janfrode@tanso.net>
To: git-commits@fedoraproject.org
Subject: [rpms/trafficserver] trafficserver-9.2.14-1: Introduce new systemd-rpm macros in trafficserver spec file
Date: Wed, 15 Jul 2026 17:20:40 GMT	[thread overview]
Message-ID: <178413604056.1.12688405630096098922.rpms-trafficserver-2cbf89ca6a72@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/trafficserver
Branch : trafficserver-9.2.14-1
Commit : 2cbf89ca6a7284f7a4ae5275b7bce45a9cd2de24
Author : Jan-Frode Myklebust <janfrode@tanso.net>
Date   : 2012-08-27T11:54:06+02:00
Stats  : +20/-19 in 1 file(s)
URL    : https://src.fedoraproject.org/rpms/trafficserver/c/2cbf89ca6a7284f7a4ae5275b7bce45a9cd2de24?branch=trafficserver-9.2.14-1

Log:
Introduce new systemd-rpm macros in trafficserver spec file

---
diff --git a/trafficserver.spec b/trafficserver.spec
index 5970581..a9380f7 100644
--- a/trafficserver.spec
+++ b/trafficserver.spec
@@ -3,7 +3,7 @@
 Summary:	Fast, scalable and extensible HTTP/1.1 compliant caching proxy server
 Name:		trafficserver
 Version:	3.2.0
-Release:	5%{?dist}
+Release:	6%{?dist}
 License:	ASL 2.0
 Group:		System Environment/Daemons
 Source0:	http://www.apache.org/dist/%{name}/%{name}-%{version}.tar.bz2
@@ -135,13 +135,17 @@ rm -rf $RPM_BUILD_ROOT
 
 %post
 /sbin/ldconfig
-if [ $1 -eq 1 ] ; then
-%if %{?fedora}0 > 140 || %{?rhel}0 > 60
-  /bin/systemctl daemon-reload >/dev/null 2>&1 || :
+%if %{?fedora}0 > 170 || %{?rhel}0 > 60
+  %systemd_post trafficserver.service
 %else
-  /sbin/chkconfig --add %{name}
+  if [ $1 -eq 1 ] ; then
+  %if %{?fedora}0 > 140
+    /bin/systemctl daemon-reload >/dev/null 2>&1 || :
+  %else
+    /sbin/chkconfig --add %{name}
+  %endif
+  fi
 %endif
-fi
 
 %pre
 getent group ats >/dev/null || groupadd -r ats -g 176 &>/dev/null
@@ -150,30 +154,25 @@ useradd -r -u 176 -g ats -d / -s /sbin/nologin \
 	-c "Apache Traffic Server" ats &>/dev/null
 
 %preun
-if [ $1 -eq 0 ] ; then
-%if %{?fedora}0 > 140 || %{?rhel}0 > 60
-  /bin/systemctl disable trafficserver.service >/dev/null 2>&1 || :
-  /bin/systemctl stop trafficserver.service >/dev/null 2>&1 || :
+%if %{?fedora}0 > 170 || %{?rhel}0 > 60
+  %systemd_preun trafficserver.service
 %else
+if [ $1 -eq 0 ] ; then
   /sbin/service %{name} stop > /dev/null 2>&1
   /sbin/chkconfig --del %{name}
-%endif
 fi
+%endif
 
 %postun
 /sbin/ldconfig
 
-%if %{?fedora}0 > 140 || %{?rhel}0 > 60
-/bin/systemctl daemon-reload >/dev/null 2>&1 || :
-%endif
-
-if [ $1 -eq 1 ] ; then
-%if %{?fedora}0 > 140 || %{?rhel}0 > 60
-  /bin/systemctl try-restart trafficserver.service >/dev/null 2>&1 || :
+%if %{?fedora}0 > 170 || %{?rhel}0 > 60
+  %systemd_postun_with_restart trafficserver.service
 %else
+if [ $1 -eq 1 ] ; then
   /sbin/service trafficserver condrestart &>/dev/null || :
-%endif
 fi
+%endif
 
 
 %package devel
@@ -194,6 +193,8 @@ header files, and Apache httpd style module build system.
 %attr(0644,root,root) %{_libdir}/trafficserver/*.so
 
 %changelog
+* Fri Aug 24 2012 Václav Pavlín <vpavlin@redhat.com> - 3.2.0-6
+- Scriptlets replaced with new systemd macros (#851462)
 
 * Thu Aug 16 2012 Jan-Frode Myklebust <janfrode@tanso.net> - 3.2.0-5
 - Add patch for TS-1392, to fix problem with SNI fallback.

                 reply	other threads:[~2026-07-15 17:20 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=178413604056.1.12688405630096098922.rpms-trafficserver-2cbf89ca6a72@fedoraproject.org \
    --to=janfrode@tanso.net \
    --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