1.Install MongoDB
sudo sh -c 'cat << EOF > /etc/yum.repos.d/mongodb-org-3.4.repo
[mongodb-org-3.4]
name=MongoDB Repository
baseurl=https://repo.mongodb.org/yum/redhat/\$releasever/mongodb-org/3.4/x86_64/
gpgcheck=1
enabled=1
gpgkey=https://www.mongodb.org/static/pgp/server-3.4.asc
EOF'
sudo yum -y install mongodb-org
sudo systemctl start mongod
2.Install MongoDB C Driver
yum install mongo-c-driver
yum install libbson
3.Define a TUN device
Create pgwtun:
sudo yum -y install iproute
sudo ip tuntap add name pgwtun mode tun
sudo ip addr add 45.45.0.1/16 dev pgwtun
sudo ip addr add cafe::1/64 dev pgwtun
sudo ip link set pgwtun up
4.Install dependencies
Install the following dependencies:
sudo yum -y install git flex bison autoconf libtool \
lksctp-tools-devel libidn-devel gnutls-devel libgcrypt-devel \
openssl-devel cyrus-sasl-devel libyaml-devel
5.Install mongo-c-driver-devel
Wget https://kojipkgs.fedoraproject.org//packages/mongo-c-driver/1.3.6/1.el7/x86_64/mongo-c-driver-devel-1.3.6-1.el7.x86_64.rpm
yum -y install mongo-c-driver-devel-1.3.6-1.el7.x86_64.rpm
NOTE:
The mongo-c-driver-devel package must be installed, otherwise an error occurs while executing ./configure --prefix= 'PWD' /install
6.Build
git clone https://github.com/nextepc/nextepc
cd nextepc
autoreconf -iv
./configure --prefix=`pwd`/install
make -j `nproc`
make install
7.Run
./nextepc-epcd
8.Install Node.js
Node.js is required to install NextEPC WebUI:
curl --silent --location https://rpm.nodesource.com/setup_10.x | sudo bash -
sudo yum -y install nodejs
9.Install the dependencies of WebUI
cd webui
npm install
10.Run WebUI
npm run dev
Visit http://localhost:3000