-
Notifications
You must be signed in to change notification settings - Fork 0
Install from source
Lucas Baleeiro Dominato edited this page Jan 24, 2023
·
17 revisions
Install Go (assuming there is no previous version installed):
$ wget https://dl.google.com/go/go1.14.4.linux-amd64.tar.gz
$ sudo tar -C /usr/local -zxvf go1.14.4.linux-amd64.tar.gz
$ mkdir -p ~/go/{bin,pkg,src}
$ echo 'export GOPATH=$HOME/go' >> ~/.bashrc
$ echo 'export GOROOT=/usr/local/go' >> ~/.bashrc
$ echo 'export PATH=$PATH:$GOPATH/bin:$GOROOT/bin' >> ~/.bashrc
$ source ~/.bashrc
1- Download the source code:
$ git clone https://github.com/my5G/Reverse-proxy.git
2- Install the dependencies:
$ cd Reverse-proxy
$ go mod download
3- Build the binary:
$ cd cmd
$ go build app.go
4- Edit configuration file and make the following procedures.
- Configure http with the HTTP IP address and its port. You will need to use HTTP server and its API REST for configuration of AMFs. For example:
http:
ip: "127.0.0.1"
port: 8080
- Configure sctp with the Reverse Proxy IP address and its port. You will need to use these information to connect with your GNB/N3IWF. For example:
sctp:
ip: "127.0.0.1"
port: 9488
- Use the API REST of Reverse proxy to configure AMFs for load balacing of SCTP connections:
- For more information see the usage page.
curl --location --request POST 'http://127.0.0.1:8080/api/v1/amf' --header 'Content-Type: application/json' --data-raw '{
"name": "amf1",
"ip": "127.0.0.1",
"port": 38412,
"state": 1
}'
curl --location --request POST 'http://127.0.0.1:8080/api/v1/amf' --header 'Content-Type: application/json' --data-raw '{
"name": "amf2",
"ip": "127.0.0.1",
"port": 38413,
"state": 1
}'
5- Representing Topology:
Done! The software is successfully installed.