Created
September 1, 2016 18:53
-
-
Save Dedsec1/dd4799a043949bbf3b5f86d28f29ac88 to your computer and use it in GitHub Desktop.
All in one installer for Netdata, FireHOL and IPRange
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
LC_ALL=C | |
# you need to install a basic build environment | |
# this is for ubuntu, change it according to your needs for other systems | |
# apt-get install zlib1g-dev gcc make git autoconf autogen automake pkg-config traceroute ipset curl nodejs || exit 1 | |
for x in iprange firehol netdata | |
do | |
if [ ! -d /usr/src/${x}.git ] | |
then | |
echo "Downloading (git clone) ${x}..." | |
git clone https://github.com/firehol/${x}.git /usr/src/${x}.git || exit 1 | |
else | |
echo "Downloading (git pull) ${x}..." | |
cd /usr/src/${x}.git || exit 1 | |
git pull || exit 1 | |
fi | |
done | |
echo | |
echo "Building iprange..." | |
cd /usr/src/iprange.git || exit 1 | |
./autogen.sh || exit 1 | |
./configure --prefix=/usr CFLAGS="-march=native -O3" --disable-man || exit 1 | |
make || exit 1 | |
make install || exit 1 | |
echo | |
echo "Building firehol..." | |
cd /usr/src/firehol.git || exit 1 | |
./autogen.sh || exit 1 | |
./configure --prefix=/usr --sysconfdir=/etc --disable-man --disable-doc || exit 1 | |
make || exit 1 | |
make install || exit 1 | |
echo | |
echo "Building netdata..." | |
cd /usr/src/netdata.git || exit 1 | |
./netdata-installer.sh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment