update to 1.3.22 and add logrotate script
This commit is contained in:
parent
1a1a0def7b
commit
d36291d8e5
@ -1,3 +1,4 @@
|
|||||||
haproxy-1.3.19.tar.gz
|
haproxy-1.3.19.tar.gz
|
||||||
haproxy-1.3.20.tar.gz
|
haproxy-1.3.20.tar.gz
|
||||||
haproxy-1.3.21.tar.gz
|
haproxy-1.3.21.tar.gz
|
||||||
|
haproxy-1.3.22.tar.gz
|
||||||
|
17
haproxy.cfg
17
haproxy.cfg
@ -10,7 +10,21 @@
|
|||||||
# Global settings
|
# Global settings
|
||||||
#---------------------------------------------------------------------
|
#---------------------------------------------------------------------
|
||||||
global
|
global
|
||||||
|
# to have these messages end up in /var/log/haproxy.log you will
|
||||||
|
# need to:
|
||||||
|
#
|
||||||
|
# 1) configure syslog to accept network log events. This is done
|
||||||
|
# by adding the '-r' option to the SYSLOGD_OPTIONS in
|
||||||
|
# /etc/sysconfig/syslog
|
||||||
|
#
|
||||||
|
# 2) configure local2 events to go to the /var/log/haproxy.log
|
||||||
|
# file. A line like the following can be added to
|
||||||
|
# /etc/sysconfig/syslog
|
||||||
|
#
|
||||||
|
# local2.* /var/log/haproxy.log
|
||||||
|
#
|
||||||
log 127.0.0.1 local2
|
log 127.0.0.1 local2
|
||||||
|
|
||||||
chroot /var/lib/haproxy
|
chroot /var/lib/haproxy
|
||||||
pidfile /var/run/haproxy.pid
|
pidfile /var/run/haproxy.pid
|
||||||
maxconn 4000
|
maxconn 4000
|
||||||
@ -18,6 +32,9 @@ global
|
|||||||
group haproxy
|
group haproxy
|
||||||
daemon
|
daemon
|
||||||
|
|
||||||
|
# turn on stats unix socket
|
||||||
|
stats socket /var/lib/haproxy/stats
|
||||||
|
|
||||||
#---------------------------------------------------------------------
|
#---------------------------------------------------------------------
|
||||||
# common defaults that all the 'listen' and 'backend' sections will
|
# common defaults that all the 'listen' and 'backend' sections will
|
||||||
# use if not designated in their block
|
# use if not designated in their block
|
||||||
|
12
haproxy.logrotate
Normal file
12
haproxy.logrotate
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
/var/log/haproxy.log {
|
||||||
|
daily
|
||||||
|
rotate 10
|
||||||
|
missingok
|
||||||
|
notifempty
|
||||||
|
compress
|
||||||
|
sharedscripts
|
||||||
|
postrotate
|
||||||
|
/bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true
|
||||||
|
/bin/kill -HUP `cat /var/run/rsyslogd.pid 2> /dev/null` 2> /dev/null || true
|
||||||
|
endscript
|
||||||
|
}
|
@ -5,7 +5,7 @@
|
|||||||
%define haproxy_datadir %{_datadir}/haproxy
|
%define haproxy_datadir %{_datadir}/haproxy
|
||||||
|
|
||||||
Name: haproxy
|
Name: haproxy
|
||||||
Version: 1.3.21
|
Version: 1.3.22
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: HA-Proxy is a TCP/HTTP reverse proxy for high availability environments
|
Summary: HA-Proxy is a TCP/HTTP reverse proxy for high availability environments
|
||||||
|
|
||||||
@ -16,6 +16,7 @@ URL: http://haproxy.1wt.eu/
|
|||||||
Source0: http://haproxy.1wt.eu/download/1.3/src/haproxy-%{version}.tar.gz
|
Source0: http://haproxy.1wt.eu/download/1.3/src/haproxy-%{version}.tar.gz
|
||||||
Source1: %{name}.init
|
Source1: %{name}.init
|
||||||
Source2: %{name}.cfg
|
Source2: %{name}.cfg
|
||||||
|
Source3: %{name}.logrotate
|
||||||
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
BuildRequires: pcre-devel
|
BuildRequires: pcre-devel
|
||||||
@ -63,6 +64,7 @@ make install-man DESTDIR=%{buildroot} PREFIX=%{_prefix}
|
|||||||
|
|
||||||
%{__install} -p -D -m 0755 %{SOURCE1} %{buildroot}%{_initrddir}/%{name}
|
%{__install} -p -D -m 0755 %{SOURCE1} %{buildroot}%{_initrddir}/%{name}
|
||||||
%{__install} -p -D -m 0644 %{SOURCE2} %{buildroot}%{haproxy_confdir}/%{name}.cfg
|
%{__install} -p -D -m 0644 %{SOURCE2} %{buildroot}%{haproxy_confdir}/%{name}.cfg
|
||||||
|
%{__install} -p -D -m 0644 %{SOURCE3} %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
|
||||||
%{__install} -d -m 0755 %{buildroot}%{haproxy_home}
|
%{__install} -d -m 0755 %{buildroot}%{haproxy_home}
|
||||||
%{__install} -d -m 0755 %{buildroot}%{haproxy_datadir}
|
%{__install} -d -m 0755 %{buildroot}%{haproxy_datadir}
|
||||||
|
|
||||||
@ -120,6 +122,7 @@ fi
|
|||||||
%dir %{haproxy_datadir}/*
|
%dir %{haproxy_datadir}/*
|
||||||
%dir %{haproxy_confdir}
|
%dir %{haproxy_confdir}
|
||||||
%config(noreplace) %{haproxy_confdir}/%{name}.cfg
|
%config(noreplace) %{haproxy_confdir}/%{name}.cfg
|
||||||
|
%config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
|
||||||
%{_initrddir}/%{name}
|
%{_initrddir}/%{name}
|
||||||
%{_sbindir}/%{name}
|
%{_sbindir}/%{name}
|
||||||
%{_mandir}/man1/%{name}.1.gz
|
%{_mandir}/man1/%{name}.1.gz
|
||||||
@ -127,6 +130,10 @@ fi
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat Oct 17 2009 Jeremy Hinegardner <jeremy at hinegardner dot org> - 1.3.22-1
|
||||||
|
- update to 1.3.22
|
||||||
|
- added logrotate configuration
|
||||||
|
|
||||||
* Mon Oct 12 2009 Jeremy Hinegardner <jeremy at hinegardner dot org> - 1.3.21-1
|
* Mon Oct 12 2009 Jeremy Hinegardner <jeremy at hinegardner dot org> - 1.3.21-1
|
||||||
- update to 1.3.21
|
- update to 1.3.21
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user