[trafficserver] Initial import of apache traffic server into SCM.

Jan-Frode Myklebust janfrode at fedoraproject.org
Mon Mar 12 13:08:32 UTC 2012


commit e512a62c13f741b4b51eaf310f3a0e35494d555d
Author: Jan-Frode Myklebust <janfrode at tanso.net>
Date:   Mon Mar 12 14:08:01 2012 +0100

    Initial import of apache traffic server into SCM.

 .gitignore                                  |    1 +
 sources                                     |    1 +
 trafficserver-cluster_interface_linux.patch |   13 ++
 trafficserver-condrestart.patch             |   11 ++
 trafficserver-init_scripts.patch            |  219 +++++++++++++++++++++++++++
 trafficserver.spec                          |  212 ++++++++++++++++++++++++++
 trafficserver.sysconf                       |   13 ++
 trafficserver_make_install.patch            |   24 +++
 8 files changed, 494 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..5c8a093 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/trafficserver-3.0.3.tar.bz2
diff --git a/sources b/sources
index e69de29..7a11b4c 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+4af9392a847f3fde39a3c6cd33e78f50  trafficserver-3.0.3.tar.bz2
diff --git a/trafficserver-cluster_interface_linux.patch b/trafficserver-cluster_interface_linux.patch
new file mode 100644
index 0000000..4f50262
--- /dev/null
+++ b/trafficserver-cluster_interface_linux.patch
@@ -0,0 +1,13 @@
+diff --git a/proxy/config/records.config.default.in b/proxy/config/records.config.default.in
+index a8ea86c..9caad1d 100644
+--- a/proxy/config/records.config.default.in
++++ b/proxy/config/records.config.default.in
+@@ -300,7 +300,7 @@ CONFIG proxy.config.cluster.mcport INT 8089
+ CONFIG proxy.config.cluster.mc_group_addr STRING 224.0.1.37
+ CONFIG proxy.config.cluster.mc_ttl INT 1
+ CONFIG proxy.config.cluster.log_bogus_mc_msgs INT 1
+-CONFIG proxy.config.cluster.ethernet_interface STRING @default_net_iface@
++CONFIG proxy.config.cluster.ethernet_interface STRING lo
+ ##############################################################################
+ #
+ # Cache
diff --git a/trafficserver-condrestart.patch b/trafficserver-condrestart.patch
new file mode 100644
index 0000000..0ae9e0a
--- /dev/null
+++ b/trafficserver-condrestart.patch
@@ -0,0 +1,11 @@
+--- trafficserver-3.0.2/rc/trafficserver.in.orig	2011-12-08 09:29:05.667600751 +0100
++++ trafficserver-3.0.2/rc/trafficserver.in	2011-12-08 09:29:15.801467183 +0100
+@@ -386,7 +386,7 @@
+   ;;
+   condrestart)
+     if [ "$DISTRIB_ID" = "fedora" -o "$DISTRIB_ID" = "redhat" ]; then
+-      if ! $0 'status'
++      if $0 'status'
+       then
+         sh $0 'stop'
+         sh $0 'start'
diff --git a/trafficserver-init_scripts.patch b/trafficserver-init_scripts.patch
new file mode 100644
index 0000000..6d4a2b8
--- /dev/null
+++ b/trafficserver-init_scripts.patch
@@ -0,0 +1,219 @@
+diff --git a/rc/trafficserver.in b/rc/trafficserver.in
+index 6582984..7191cdb 100644
+--- a/rc/trafficserver.in
++++ b/rc/trafficserver.in
+@@ -15,13 +15,21 @@
+ # See the License for the specific language governing permissions and
+ # limitations under the License.
+ #
+-# Template from /etc/init.d/skeleton on Ubuntu
++# trafficserver    Startup/shutdown script for the Apache Traffic Server
++#
++# chkconfig: - 90 10
++# description: TApache Traffic Server is fast, scalable and extensible  \
++#	       HTTP/1.1 compliant caching proxy server.
++# processname: traffic_cop traffic_manager traffic_server
++# config: /etc/trafficserver
++# config: /etc/sysconfig/trafficserver
++# pidfile: /var/run/trafficserver/cop.pid
+ #
+ ### BEGIN INIT INFO
+ # Provides:          Traffic Server
+ # Required-Start:    $local_fs $remote_fs
+ # Required-Stop:     $local_fs $remote_fs
+-# Default-Start:     2 3 4 5
++# Default-Start:     -
+ # Default-Stop:      S 0 1 6
+ # Short-Description: Startup/shutdown script for the Apache Traffic Server
+ # Description:       Apache Traffic Server is fast, scalable and extensible
+@@ -41,6 +49,33 @@ TS_PACKAGE_VERSION="@PACKAGE_VERSION@"
+ TS_PACKAGE_BUGREPORT="@PACKAGE_BUGREPORT@"
+ UNAME_S=$(uname -s)
+ 
++# Ubuntu: Do NOT "set -e"
++#         PATH should only include /usr/* if it runs after the mountnfs.sh
++PATH=/usr/sbin:/usr/bin:/sbin:/bin
++DESC="start/stop Traffic Server"
++NAME=trafficserver
++
++TC_NAME=${TC_NAME:-traffic_cop}
++TM_NAME=${TM_NAME:-traffic_manager}
++TS_NAME=${TS_NAME:-traffic_server}
++TC_DAEMON=${TC_DAEMON:- at exp_bindir@/${TC_NAME}}
++TC_DAEMON_ARGS=""
++TM_DAEMON=${TM_DAEMON:- at exp_bindir@/${TM_NAME}}
++TM_DAEMON_ARGS=""
++TS_DAEMON=${TS_DAEMON:- at exp_bindir@/${TS_NAME}}
++TS_DAEMON_ARGS=""
++TC_PIDFILE=${TC_PIDFILE:- at exp_runtimedir@/cop.lock}
++TM_PIDFILE=${TM_PIDFILE:- at exp_runtimedir@/manager.lock}
++TS_PIDFILE=${TS_PIDFILE:- at exp_runtimedir@/server.lock}
++LOCKFILE=${LOCKFILE-/var/lock/subsys/trafficserver}
++# number of times to retry check on pid lock file
++PIDFILE_CHECK_RETRIES=${PIDFILE_CHECK_RETRIES:-30}
++
++HEAD=/usr/bin/head
++test -x $HEAD || HEAD=head
++ESED=/usr/bin/sed
++test -x $ESED || ESED=sed
++
+ if [ -e /etc/SuSE-release ]; then
+   DISTRIB_ID="suse"
+ elif [ -e /etc/fedora-release ]; then
+@@ -48,6 +83,8 @@ elif [ -e /etc/fedora-release ]; then
+ elif [ -e /etc/redhat-release ]; then
+   DISTRIB_ID="redhat" # also exists on Fedora
+ elif [ -e /etc/lsb-release ]; then
++  ## TODO: here is a trap for other distributions
++  ##       should use /usr/bin/lsb_release -i -s
+   DISTRIB_ID="ubuntu"
+ elif [ -e /etc/debian_version ]; then
+   DISTRIB_ID="debian" # also exists on Ubuntu
+@@ -57,53 +94,27 @@ elif [ "$UNAME_S" = "Darwin" ]; then
+   DISTRIB_ID="Darwin"
+ elif [ "$UNAME_S" = "FreeBSD" ]; then
+   DISTRIB_ID="FreeBSD"
++else
++  echo "This script needs to be ported to this OS"
++  exit 1
+ fi
+ 
+-# /usr/bin/lsb_release -rd # Ubuntu release & description info
+-
+-HEAD=/usr/bin/head
+-test -x $HEAD || HEAD=head
+-ESED=/usr/bin/sed
+-test -x $ESED || ESED=sed
+-
+-# Ubuntu: Do NOT "set -e"
+-
+-#Ubuntu:PATH should only include /usr/* if it runs after the mountnfs.sh script
+-PATH=/usr/sbin:/usr/bin:/sbin:/bin
+-DESC="start/stop Traffic Server"
+-NAME=trafficserver
+-TS_PREFIX="@prefix@"
+-
+-TS_ROOT=${TS_ROOT:-$TS_PREFIX}
+-# TS_BASE is offset inside the file system from where the layout starts
+-# For standard installations TS_BASE will be empty
+-eval TS_BASE="`echo $TS_ROOT | ${ESED} -e 's;@prefix@$;;'`"
+-
+-TC_NAME=${TC_NAME:-traffic_cop}
+-TM_NAME=${TM_NAME:-traffic_manager}
+-TS_NAME=${TS_NAME:-traffic_server}
+-TC_DAEMON=${TC_DAEMON:-$TS_BASE at exp_bindir@/traffic_cop}
+-TC_DAEMON_ARGS=""
+-TM_DAEMON=${TM_DAEMON:-$TS_BASE at exp_bindir@/traffic_manager}
+-TM_DAEMON_ARGS=""
+-TS_DAEMON=${TS_DAEMON:-$TS_BASE at exp_bindir@/traffic_server}
+-TS_DAEMON_ARGS=""
+-TC_PIDFILE=${TC_PIDFILE:-$TS_BASE at exp_runtimedir@/cop.lock}
+-TM_PIDFILE=${TM_PIDFILE:-$TS_BASE at exp_runtimedir@/manager.lock}
+-TS_PIDFILE=${TS_PIDFILE:-$TS_BASE at exp_runtimedir@/server.lock}
+-# number of times to retry check on pid lock file
+-PIDFILE_CHECK_RETRIES=${PIDFILE_CHECK_RETRIES:-30}
+-# stdout file of executable
+-STDOUTLOG=${STDOUTLOG:-$TS_BASE at exp_logdir@/traffic_server.stdout}
+-# stderr file of executable
+-STDERRLOG=${STDERRLOG:-$TS_BASE at exp_logdir@/traffic_server.stderr}
+-
+ if [ -d /etc/rc.d/init.d ]; then
+-  SCRIPTNAME=/etc/rc.d/init.d/$NAME # Fedora
++  # Fedora & Redhat
++  SCRIPTNAME=/etc/rc.d/init.d/$NAME
++  test -f /etc/rc.d/init.d/functions && . /etc/rc.d/init.d/functions
++  test -r /etc/sysconfig/$NAME && . /etc/sysconfig/$NAME
+ elif [ -d /etc/init.d ]; then
+-  SCRIPTNAME=/etc/init.d/$NAME # Ubuntu
++  # Ubuntu & Debian
++  SCRIPTNAME=/etc/init.d/$NAME
++  test -r /etc/default/$NAME && . /etc/default/$NAME
++  test -f /etc/default/rcS && . /etc/default/rcS
++  # Ubuntu: Define LSB log_* functions.
++  #         Depend on lsb-base (>= 3.0-6) to ensure that this file is present.
++  test -f /lib/lsb/init-functions && . /lib/lsb/init-functions
+ elif [ "$DISTRIB_ID" = "Darwin" ]; then
+-  SCRIPTNAME=$0 # Darwin
++  # Darwin
++  SCRIPTNAME=$0
+ elif [ "$DISTRIB_ID" = "FreeBSD" ]; then
+   SCRIPTNAME=$0 # FreeBSD 
+ else
+@@ -111,7 +122,6 @@ else
+   exit 1
+ fi
+ 
+-
+ # Exit if the package can not be found
+ if [ ! -x "$TS_DAEMON" ]; then
+   echo "Error: Can not find $TS_DAEMON using TS_ROOT=$TS_ROOT"
+@@ -119,42 +129,18 @@ if [ ! -x "$TS_DAEMON" ]; then
+   exit 0
+ fi
+ 
+-# Ubuntu: Read configuration variable file if it is present
+-test -r /etc/default/$NAME && . /etc/default/$NAME
+-
+-# Ubuntu: Load the VERBOSE setting and other rcS variables
+-test -f /etc/default/rcS && . /etc/default/rcS
+-
+-# Suse: load rc.status
+-test -f /etc/rc.status && . /etc/rc.status
+-
+-# Fedora: make avail helper functions 'action', 'killproc', 'status', etc
+-test -f /etc/rc.d/init.d/functions && . /etc/rc.d/init.d/functions
+-
+-# Ubuntu: Define LSB log_* functions.
+-#         Depend on lsb-base (>= 3.0-6) to ensure that this file is present.
+-test -f /lib/lsb/init-functions && . /lib/lsb/init-functions
+-
+-# FreeBSD
+-# NB: FreeBSD's ports system installs a run script in /usr/local/etc/rc.d/ 
+-# with native OS rc.subr(8) features.
+-test -f /etc/rc.subr && . /etc/rc.subr
+-
+-
+ #
+ # Fedora:
+ #  launches $* in the background
+ #  and checks if program creates its own pid lock file
+-#  redirects stdout and stderr to files
+ #  this function is meant to substitute 'daemon'
+ #  because 'daemon' expects $1 to fork itself
+ forkdaemon()
+ {
+   local i=0
+ 
+-  # launch in background, i.e. fork
+-  # and redirect stdout and stderr to files
+-  $* >> $STDOUTLOG 2>> $STDERRLOG &
++  # launch in background, cop will redirect STDIN STDOUT to /dev/null
++  $* &
+ 
+   while (( $i < $PIDFILE_CHECK_RETRIES ))
+   do
+@@ -162,6 +148,7 @@ forkdaemon()
+     # check for regular file and size greater than 0
+     if [[ -f $TC_PIDFILE ]] && [[ -s $TC_PIDFILE ]]
+     then
++      touch $LOCKFILE
+       success
+       return 0
+     fi
+@@ -265,7 +252,7 @@ case "$1" in
+     elif [ "$DISTRIB_ID" = "Darwin" ]; then
+       echo "Starting ${TS_PACKAGE_NAME}"
+       launchctl list $TC_NAME > /dev/null 2>&1 && exit 0
+-      launchctl submit -l $TC_NAME -p $TC_DAEMON -o $STDOUTLOG -e $STDERRLOG -- $TC_DAEMON_ARGS
++      launchctl submit -l $TC_NAME -p $TC_DAEMON -o /dev/null -e /dev/null -- $TC_DAEMON_ARGS
+     elif [ "$DISTRIB_ID" = "FreeBSD" ]; then
+       echo "Starting ${TS_PACKAGE_NAME}"
+       name="$TC_NAME"
+@@ -290,6 +277,7 @@ case "$1" in
+       action "Stopping ${TC_NAME}:" killproc -p $TC_PIDFILE $TC_DAEMON
+       action "Stopping ${TM_NAME}:" killproc -p $TM_PIDFILE $TM_DAEMON
+       action "Stopping ${TS_NAME}:" killproc -p $TS_PIDFILE $TS_DAEMON
++      rm -f $LOCKFILE
+     elif [ "$DISTRIB_ID" = "suse" ]; then
+       echo -n "Stopping ${TC_NAME}"
+       killproc -p $TC_PIDFILE $TC_DAEMON
diff --git a/trafficserver.spec b/trafficserver.spec
new file mode 100644
index 0000000..a1e39eb
--- /dev/null
+++ b/trafficserver.spec
@@ -0,0 +1,212 @@
+# FIXME: provide systemd startup for rawhide/F15
+#	https://fedoraproject.org/wiki/Packaging:Guidelines:Systemd
+Summary:	Fast, scalable and extensible HTTP/1.1 compliant caching proxy server
+Name:		trafficserver
+Version:	3.0.3
+Release:	1%{?dist}
+License:	ASL 2.0
+Group:		System Environment/Daemons
+Source0:	http://www.apache.org/dist/%{name}/%{name}-%{version}.tar.bz2
+Source1:	trafficserver.sysconf
+URL:		http://trafficserver.apache.org/index.html
+# BuildRoot is only needed for EPEL5:
+BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
+BuildRequires:	autoconf, automake, libtool, openssl-devel, tcl-devel, expat-devel
+BuildRequires:	pcre-devel, zlib-devel, xz-devel, gcc-c++
+
+Patch2:		trafficserver-init_scripts.patch
+Patch7:		trafficserver_make_install.patch
+Patch51:	trafficserver-cluster_interface_linux.patch
+# Fixed on v3.1:
+Patch52:	trafficserver-condrestart.patch
+
+
+%description
+Apache Traffic Server is fast, scalable and extensible HTTP/1.1 compliant
+caching proxy server.
+
+%prep
+%setup -q
+
+%patch2 -p1 -b .patch2
+%patch7 -p1 -b .patch7
+%patch51 -p1 -b .patch51
+%patch52 -p1 -b .patch52
+
+%build
+./configure --enable-layout=Gentoo --libdir=%{_libdir}/trafficserver --with-tcl=%{_libdir} --with-user=ats --with-group=ats
+make %{?_smp_mflags}
+
+%install
+echo $RPM_BUILD_ROOT
+rm -rf $RPM_BUILD_ROOT
+make DESTDIR=$RPM_BUILD_ROOT install
+
+# the traffic_shell manual conflict with bash: exit enable,
+# so we rename these to ts-enable, ts-exit and ts-disable.
+mkdir -p $RPM_BUILD_ROOT/usr/share/man/man1
+cp doc/man/*.1 $RPM_BUILD_ROOT/usr/share/man/man1/
+mv $RPM_BUILD_ROOT/usr/share/man/man1/enable.1 \
+$RPM_BUILD_ROOT/usr/share/man/man1/ts-enable.1
+mv $RPM_BUILD_ROOT/usr/share/man/man1/disable.1 \
+$RPM_BUILD_ROOT/usr/share/man/man1/ts-disable.1
+mv $RPM_BUILD_ROOT/usr/share/man/man1/exit.1 \
+$RPM_BUILD_ROOT/usr/share/man/man1/ts-exit.1
+cat <<EOF > README.fedora
+The man-pages for enable, disable and exit was renamed to ts-enable, 
+ts-disable and ts-exit to avoid conflicts with other man-pages.
+EOF
+
+mkdir -p $RPM_BUILD_ROOT/etc/init.d/
+mv $RPM_BUILD_ROOT/usr/bin/trafficserver $RPM_BUILD_ROOT/etc/init.d
+
+mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig
+install -m 644 -p %{SOURCE1} \
+   $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/trafficserver
+
+# Remove static libs (needs to go to separate -static subpackage if we
+# want these:
+rm -f $RPM_BUILD_ROOT/%{_libdir}/trafficserver/libtsmgmt.a
+rm -f $RPM_BUILD_ROOT/%{_libdir}/trafficserver/libtsutil.a
+
+# Don't include libtool archives:
+rm -f $RPM_BUILD_ROOT/%{_libdir}/trafficserver/libtsmgmt.la
+rm -f $RPM_BUILD_ROOT/%{_libdir}/trafficserver/libtsutil.la
+rm -f $RPM_BUILD_ROOT/%{_libdir}/trafficserver/plugins/conf_remap.la
+
+# The clean section  is only needed for EPEL and Fedora < 13
+# http://fedoraproject.org/wiki/PackagingGuidelines#.25clean
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(-, ats, ats, -)
+%doc README CHANGES NOTICE README.fedora LICENSE
+%attr(0644, root, root) /usr/share/man/man1/*
+%attr(0755,root,root) /usr/bin/traffic*
+%attr(0755,root,root) %dir %{_libdir}/trafficserver
+%attr(0755,root,root) %dir %{_libdir}/trafficserver/plugins
+%attr(0755,root,root) %{_libdir}/trafficserver/*.so.*
+%attr(0755,root,root) %{_libdir}/trafficserver/plugins/*.so
+%config(noreplace) /etc/trafficserver/*
+%attr(0755, root, root) /etc/init.d/trafficserver
+%attr(0755, ats, ats) %dir /etc/trafficserver
+%config(noreplace) %attr(0644, root, root) %{_sysconfdir}/sysconfig/trafficserver
+%dir /var/log/trafficserver
+%dir /var/run/trafficserver
+%dir /var/cache/trafficserver
+
+%post
+/sbin/ldconfig
+if [ $1 -eq 1 ] ; then
+  /sbin/chkconfig --add %{name}
+fi
+
+%pre
+getent group ats >/dev/null || groupadd -r ats -g 176 &>/dev/null
+getent passwd ats >/dev/null || \
+useradd -r -u 176 -g ats -d / -s /sbin/nologin \
+	-c "Apache Traffic Server" ats &>/dev/null
+
+%preun
+if [ $1 -eq 0 ] ; then
+  /sbin/service %{name} stop > /dev/null 2>&1
+  /sbin/chkconfig --del %{name}
+fi
+
+%postun
+/sbin/ldconfig
+if [ $1 -eq 1 ] ; then
+   /sbin/service trafficserver condrestart &>/dev/null || :
+fi
+
+
+%package devel
+Summary: Apache Traffic Server development libraries and header files
+Group: Development/Libraries
+Requires: trafficserver = %{version}-%{release}
+%description devel
+The trafficserver-devel package include plug-in development libraries and
+header files, and Apache httpd style module build system.
+
+%files devel
+%defattr(-,root,root,-)
+%attr(0755,root,root) /usr/bin/tsxs
+%attr(0755,root,root) %dir /usr/include/ts
+%attr(0644,root,root) /usr/include/ts/*
+%attr(0755,root,root) %dir %{_libdir}/trafficserver
+%attr(0755,root,root) %dir %{_libdir}/trafficserver/plugins
+%attr(0644,root,root) %{_libdir}/trafficserver/*.so
+
+%changelog
+* Sat Mar 10 2012 <janfrode at tanso.net> - 3.0.3-1
+- Removed mixed use of spaces and tabs in specfile.
+
+* Mon Feb 13 2012 <janfrode at tanso.net> - 3.0.3-0
+- Update to v3.0.3
+
+* Thu Dec 8 2011 <janfrode at tanso.net> - 3.0.2-0
+- Update to v3.0.2
+- Fix conderestart in initscript, TS-885.
+
+* Tue Jul 19 2011 <janfrode at tanso.net> - 3.0.1-0
+- Update to v3.0.1
+- Remove uninstall-hook from trafficserver_make_install.patch, removed in v3.0.1.
+
+* Thu Jun 30 2011 <janfrode at tanso.net> - 3.0.0-6
+- Note FIXME's on top.
+- Remove .la and static libs.
+- mktemp'd buildroot.
+- include license
+
+* Mon Jun 27 2011 <janfrode at tanso.net> - 3.0.0-5
+- Rename patches to start with trafficserver-.
+- Remove odd version macro.
+- Clean up mixed-use-of-spaces-and-tabs.
+
+* Wed Jun 23 2011 <janfrode at tanso.net> - 3.0.0-4
+- Use dedicated user/group ats/ats.
+- Restart on upgrades.
+
+* Thu Jun 16 2011 <zym at apache.org> - 3.0.0-3
+- update man pages, sugest from Jan-Frode Myklebust <janfrode at tanso.net>
+- patch records.config to fix the crashing with cluster iface is noexist
+- cleanup spec file
+
+* Wed Jun 15 2011 <zym at apache.org> - 3.0.0-2
+- bump to version 3.0.0 stable release
+- cleanup the spec file and patches
+
+* Tue May 24 2011 <yonghao at taobao.com> - 2.1.8-2
+- fix tcl linking
+
+* Thu May  5 2011 <yonghao at taobao.com> - 2.1.8-1
+- bump to 2.1.8
+- comment out wccp
+
+* Fri Apr  1 2011 <yonghao at taobao.com> - 2.1.7-3
+- enable wccp and fixed compile warning
+- never depends on sqlite and db4, add libz and xz-libs
+- fix libary permission, do post ldconfig updates
+
+* Sun Mar 27 2011 <yonghao at taobao.com> - 2.1.7-2
+- patch traffic_shell fix
+
+* Tue Mar 22 2011 <yonghao at taobao.com> - 2.1.7-1
+- bump to v2.1.7
+- fix centos5 building
+- drop duplicated patches
+
+* Tue Mar 19 2011 <yonghao at taobao.com> - 2.1.6-2
+- fix gcc 4.6 building
+- split into -devel package for devel libs
+- fix init scripts for rpmlint requirement
+- fix install scripts to build in mock, without root privileges
+
+* Tue Mar 01 2011 <yonghao at taobao.com> - 2.1.6-1
+- bump to 2.1.6 unstable
+- replace config layout name as Fedora
+
+* Thu Nov 18 2010 <yonghao at taobao.com> - 2.1.4
+- initial release for public
+- original spec file is from neomanontheway at gmail.com
diff --git a/trafficserver.sysconf b/trafficserver.sysconf
new file mode 100644
index 0000000..fff8f1f
--- /dev/null
+++ b/trafficserver.sysconf
@@ -0,0 +1,13 @@
+# Config file for /etc/init.d/trafficserver
+#
+# Traffic Cop args:
+# default is empty 
+#TC_DAEMON_ARGS=''
+#
+# Traffic Manager args:
+# default is empty 
+#TM_DAEMON_ARGS=''
+#
+# Traffic Server args:
+# default is empty 
+#TS_DAEMON_ARGS=''
diff --git a/trafficserver_make_install.patch b/trafficserver_make_install.patch
new file mode 100644
index 0000000..548ee7c
--- /dev/null
+++ b/trafficserver_make_install.patch
@@ -0,0 +1,24 @@
+--- trafficserver-3.0.1/proxy/Makefile.in.bak	2011-07-19 08:30:02.479502097 +0200
++++ trafficserver-3.0.1/proxy/Makefile.in	2011-07-19 08:34:44.913630387 +0200
+@@ -1238,17 +1238,17 @@
+ 
+ 
+ install-data-local:
+-	$(INSTALL) -d -o $(pkgsysuser) -g $(pkgsysgroup) $(DESTDIR)$(pkglocalstatedir) $(DESTDIR)$(pkglogdir) $(DESTDIR)$(pkgruntimedir) $(DESTDIR)$(pkgsysconfdir) $(DESTDIR)$(pkgsysconfdir)/internal $(DESTDIR)$(pkgdatadir) $(DESTDIR)$(pkgcachedir)
++	if [ `id -un` == "root" ]; then $(INSTALL) -d -o $(pkgsysuser) -g $(pkgsysgroup) $(DESTDIR)$(pkglocalstatedir) $(DESTDIR)$(pkglogdir) $(DESTDIR)$(pkgruntimedir) $(DESTDIR)$(pkgsysconfdir) $(DESTDIR)$(pkgsysconfdir)/internal $(DESTDIR)$(pkgdatadir) $(DESTDIR)$(pkgcachedir); else $(INSTALL) -d $(DESTDIR)$(pkglocalstatedir) $(DESTDIR)$(pkglogdir) $(DESTDIR)$(pkgruntimedir) $(DESTDIR)$(pkgsysconfdir) $(DESTDIR)$(pkgsysconfdir)/internal $(DESTDIR)$(pkgdatadir) $(DESTDIR)$(pkgcachedir); fi
+ 
+ install-data-hook:
+-	-chown -R $(pkgsysuser):$(pkgsysgroup) $(DESTDIR)$(pkgsysconfdir) $(DESTDIR)$(pkgdatadir)
++	if [ `id -un` == "root" ]; then chown -R $(pkgsysuser):$(pkgsysgroup) $(DESTDIR)$(pkgsysconfdir) $(DESTDIR)$(pkgdatadir);fi
+ 	-echo "<TS_VERSION> $(PACKAGE_VERSION)" > $(DESTDIR)$(pkgsysconfdir)/trafficserver-release
+ 
+ install-exec-local:
+-	$(INSTALL) -d -o $(pkgsysuser) -g $(pkgsysgroup) $(DESTDIR)$(pkglibexecdir)
++	if [ `id -un` == "root" ]; then $(INSTALL) -d -o $(pkgsysuser) -g $(pkgsysgroup) $(DESTDIR)$(pkglibexecdir); else $(INSTALL) -d $(DESTDIR)$(pkglibexecdir); fi
+ 
+ install-exec-hook:
+-	-chown -R $(pkgsysuser):$(pkgsysgroup) $(DESTDIR)$(pkglibexecdir)
++	if [ `id -un` == "root" ]; then chown -R $(pkgsysuser):$(pkgsysgroup) $(DESTDIR)$(pkglibexecdir);fi
+ 
+ # Tell versions [3.59,3.63) of GNU make to not export all variables.
+ # Otherwise a system limit (for SysV at least) may be exceeded.


More information about the scm-commits mailing list