Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
executable file 22 lines (18 sloc) 709 Bytes
echo "-----------------------------------------------------------------------"
echo "Now will install Haproxy $VERSION..."
curl -O$VERSION.tar.gz
tar zxf haproxy-$VERSION.tar.gz
cd haproxy-$VERSION
make TARGET=linux26 && sudo make install
cd ..
sudo rm -R haproxy-$VERSION
rm haproxy-$VERSION.tar.gz
echo "Haproxy install successed."
echo "-----------------------------------------------------------------------"
echo "Now install service to /etc/init.d ..."
sudo cp haproxy /etc/init.d/haproxy
sudo chmod +x /etc/init.d/haproxy
sudo update-rc.d haproxy defaults
sudo cp haproxy.cfg /usr/local/etc/haproxy.cfg
sudo /etc/init.d/haproxy start