From: git@ipfire.org
To: ipfire-scm@lists.ipfire.org
Subject: [git.ipfire.org] IPFire 2.x development tree branch, next, updated. 0f0e30dced66fd281573c10b366d3add83ca3d16
Date: Thu, 05 Mar 2015 14:48:27 +0100 [thread overview]
Message-ID: <20150305134828.2F00A21EF6@argus.ipfire.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 11608 bytes --]
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "IPFire 2.x development tree".
The branch, next has been updated
via 0f0e30dced66fd281573c10b366d3add83ca3d16 (commit)
via e0fe704b6eee95af512e3c9e6160ead8c5769c5e (commit)
from 970cf3363711cc835b2375b3f5ed20d5eb3c120b (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 0f0e30dced66fd281573c10b366d3add83ca3d16
Author: Michael Tremer <michael.tremer(a)ipfire.org>
Date: Thu Mar 5 14:48:16 2015 +0100
haproxy: New package
commit e0fe704b6eee95af512e3c9e6160ead8c5769c5e
Author: Michael Tremer <michael.tremer(a)ipfire.org>
Date: Thu Mar 5 13:44:50 2015 +0100
Accidentially disabled nmap build
-----------------------------------------------------------------------
Summary of changes:
config/backup/includes/haproxy | 1 +
config/haproxy/haproxy.cfg | 86 +++++++++++++++++++++++++++++++++++++++
config/rootfiles/packages/haproxy | 8 ++++
lfs/{keepalived => haproxy} | 31 ++++++++------
make.sh | 3 +-
src/initscripts/init.d/haproxy | 47 +++++++++++++++++++++
6 files changed, 163 insertions(+), 13 deletions(-)
create mode 100644 config/backup/includes/haproxy
create mode 100644 config/haproxy/haproxy.cfg
create mode 100644 config/rootfiles/packages/haproxy
copy lfs/{keepalived => haproxy} (81%)
create mode 100644 src/initscripts/init.d/haproxy
Difference in files:
diff --git a/config/backup/includes/haproxy b/config/backup/includes/haproxy
new file mode 100644
index 0000000..4516e18
--- /dev/null
+++ b/config/backup/includes/haproxy
@@ -0,0 +1 @@
+/etc/haproxy/haproxy.cfg
diff --git a/config/haproxy/haproxy.cfg b/config/haproxy/haproxy.cfg
new file mode 100644
index 0000000..324ad5e
--- /dev/null
+++ b/config/haproxy/haproxy.cfg
@@ -0,0 +1,86 @@
+#---------------------------------------------------------------------
+# Example configuration for a possible web application. See the
+# full configuration options online.
+#
+# http://haproxy.1wt.eu/download/1.4/doc/configuration.txt
+#
+#---------------------------------------------------------------------
+
+#---------------------------------------------------------------------
+# Global settings
+#---------------------------------------------------------------------
+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
+
+ chroot /var/lib/haproxy
+ pidfile /var/run/haproxy.pid
+ maxconn 4000
+ user haproxy
+ group haproxy
+ daemon
+
+ # turn on stats unix socket
+ stats socket /var/lib/haproxy/stats
+
+#---------------------------------------------------------------------
+# common defaults that all the 'listen' and 'backend' sections will
+# use if not designated in their block
+#---------------------------------------------------------------------
+defaults
+ mode http
+ log global
+ option httplog
+ option dontlognull
+ option http-server-close
+ option forwardfor except 127.0.0.0/8
+ option redispatch
+ retries 3
+ timeout http-request 10s
+ timeout queue 1m
+ timeout connect 10s
+ timeout client 1m
+ timeout server 1m
+ timeout http-keep-alive 10s
+ timeout check 10s
+ maxconn 3000
+
+#---------------------------------------------------------------------
+# main frontend which proxys to the backends
+#---------------------------------------------------------------------
+frontend main *:5000
+ acl url_static path_beg -i /static /images /javascript /stylesheets
+ acl url_static path_end -i .jpg .gif .png .css .js
+
+ use_backend static if url_static
+ default_backend app
+
+#---------------------------------------------------------------------
+# static backend for serving up images, stylesheets and such
+#---------------------------------------------------------------------
+backend static
+ balance roundrobin
+ server static 127.0.0.1:4331 check
+
+#---------------------------------------------------------------------
+# round robin balancing between the various backends
+#---------------------------------------------------------------------
+backend app
+ balance roundrobin
+ server app1 127.0.0.1:5001 check
+ server app2 127.0.0.1:5002 check
+ server app3 127.0.0.1:5003 check
+ server app4 127.0.0.1:5004 check
+
diff --git a/config/rootfiles/packages/haproxy b/config/rootfiles/packages/haproxy
new file mode 100644
index 0000000..515145d
--- /dev/null
+++ b/config/rootfiles/packages/haproxy
@@ -0,0 +1,8 @@
+#etc/haproxy
+etc/haproxy/haproxy.cfg
+etc/rc.d/init.d/haproxy
+usr/sbin/haproxy
+#usr/sbin/haproxy-systemd-wrapper
+#usr/share/man/man1/haproxy.1
+var/ipfire/backup/addons/includes/haproxy
+var/lib/haproxy
diff --git a/lfs/haproxy b/lfs/haproxy
new file mode 100644
index 0000000..febb65a
--- /dev/null
+++ b/lfs/haproxy
@@ -0,0 +1,99 @@
+###############################################################################
+# #
+# IPFire.org - A linux based firewall #
+# Copyright (C) 2013 IPFire Team <info(a)ipfire.org> #
+# #
+# This program is free software: you can redistribute it and/or modify #
+# it under the terms of the GNU General Public License as published by #
+# the Free Software Foundation, either version 3 of the License, or #
+# (at your option) any later version. #
+# #
+# This program is distributed in the hope that it will be useful, #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
+# GNU General Public License for more details. #
+# #
+# You should have received a copy of the GNU General Public License #
+# along with this program. If not, see <http://www.gnu.org/licenses/>. #
+# #
+###############################################################################
+
+###############################################################################
+# Definitions
+###############################################################################
+
+include Config
+
+VER = 1.5.11
+
+THISAPP = haproxy-$(VER)
+DL_FILE = $(THISAPP).tar.gz
+DL_FROM = $(URL_IPFIRE)
+DIR_APP = $(DIR_SRC)/$(THISAPP)
+TARGET = $(DIR_INFO)/$(THISAPP)
+PROG = haproxy
+PAK_VER = 1
+
+DEPS = ""
+
+###############################################################################
+# Top-level Rules
+###############################################################################
+
+objects = $(DL_FILE)
+
+$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
+
+$(DL_FILE)_MD5 = 5500a79d0d2b238d4a1e9749bd0c2cb2
+
+install : $(TARGET)
+
+check : $(patsubst %,$(DIR_CHK)/%,$(objects))
+
+download :$(patsubst %,$(DIR_DL)/%,$(objects))
+
+md5 : $(subst %,%_MD5,$(objects))
+
+dist:
+ @$(PAK)
+
+###############################################################################
+# Downloading, checking, md5sum
+###############################################################################
+
+$(patsubst %,$(DIR_CHK)/%,$(objects)) :
+ @$(CHECK)
+
+$(patsubst %,$(DIR_DL)/%,$(objects)) :
+ @$(LOAD)
+
+$(subst %,%_MD5,$(objects)) :
+ @$(MD5)
+
+###############################################################################
+# Installation Details
+###############################################################################
+
+$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
+ @$(PREBUILD)
+ @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
+
+ cd $(DIR_APP) && make $(MAKETUNING) CPU="generic" TARGET="linux2628" \
+ USE_OPENSSL=1 USE_PCRE=1 USE_ZLIB=1 USE_REGPARM=1 \
+ ADDINC="$(CFLAGS)" USE_LINUX_TPROXY=1 ADDLIB="$(LDFLAGS)"
+
+ cd $(DIR_APP) && make install-bin install-man PREFIX=/usr
+
+ -mkdir -pv /etc/haproxy /var/lib/haproxy
+ install -v -m 644 $(DIR_SRC)/config/haproxy/haproxy.cfg \
+ /etc/haproxy/haproxy.cfg
+
+ install -v -m 644 $(DIR_SRC)/config/backup/includes/haproxy \
+ /var/ipfire/backup/addons/includes/haproxy
+
+ # Restore initscript
+ install -v -m 754 $(DIR_SRC)/src/initscripts/init.d/haproxy \
+ /etc/rc.d/init.d/haproxy
+
+ @rm -rf $(DIR_APP)
+ @$(POSTBUILD)
diff --git a/make.sh b/make.sh
index 9309dda..7d41b59 100755
--- a/make.sh
+++ b/make.sh
@@ -649,7 +649,7 @@ buildipfire() {
ipfiremake libevent2
ipfiremake portmap
ipfiremake nfs
- #ipfiremake nmap
+ ipfiremake nmap
ipfiremake ncftp
ipfiremake etherwake
ipfiremake bwm-ng
@@ -811,6 +811,7 @@ buildipfire() {
ipfiremake pigz
ipfiremake tmux
ipfiremake swconfig
+ ipfiremake haproxy
}
buildinstaller() {
diff --git a/src/initscripts/init.d/haproxy b/src/initscripts/init.d/haproxy
new file mode 100644
index 0000000..78d64ce
--- /dev/null
+++ b/src/initscripts/init.d/haproxy
@@ -0,0 +1,47 @@
+#!/bin/sh
+########################################################################
+# Begin $rc_base/init.d/haproxy
+#
+# Description : HAProxy init script
+#
+########################################################################
+
+. /etc/sysconfig/rc
+. ${rc_functions}
+
+case "${1}" in
+ start)
+ boot_mesg "Starting HAProxy..."
+ loadproc /usr/sbin/haproxy -D -f /etc/haproxy/haproxy.cfg \
+ -p /var/run/haproxy.pid
+ ;;
+
+ stop)
+ boot_mesg "Stopping HAProxy..."
+ killproc /usr/sbin/haproxy
+ ;;
+
+ reload)
+ boot_mesg "Reloading HAProxy..."
+ /usr/sbin/haproxy -D -f /etc/haproxy/haproxy.cfg \
+ -p /var/run/haproxy.pid -sf $(cat /var/run/haproxy.pid)
+ evaluate_retval
+ ;;
+
+ restart)
+ ${0} stop
+ sleep 1
+ ${0} start
+ ;;
+
+ status)
+ statusproc /usr/sbin/haproxy
+ ;;
+
+ *)
+ echo "Usage: ${0} {start|stop|reload|restart|status}"
+ exit 1
+ ;;
+esac
+
+# End $rc_base/init.d/haproxy
hooks/post-receive
--
IPFire 2.x development tree
reply other threads:[~2015-03-05 13:48 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=20150305134828.2F00A21EF6@argus.ipfire.org \
--to=git@ipfire.org \
--cc=ipfire-scm@lists.ipfire.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