Sign inSign up

callforamerica/avaslb

By callforamerica

•Updated over 9 years ago

Avas Load Balancer

Image
0

418

callforamerica/avaslb repository overview

⁠Avas Load Balancer

⁠Usage

You will only need to install the unit file it will pull everything else it needs automatically and it will automatically pull the latest version of the image every time it restarts.

NOTE: This is a private repo so for docker to pull the image correctly you have to be logged into docker.

⁠If not logged in you need to:
docker login -u callforamerica -p <pass>
⁠Install the avaslb.service systemd unit:
cp avaslb.service /etc/systemd/system/
⁠Create the environment file:
echo "UPSTREAM_AVAS=<ip-address>,<ip-address>,<ip-address>,<ip-address>" >> /etc/default/avaslb.env
⁠Start the avaslb.service:
systemctl start avaslb
⁠If everything is working set it to auto start:
systemctl enable avaslb

⁠How to

⁠Get logs
# without follow
docker logs avaslb.service

# with follow
docker logs -f avaslb.service

# get logs for the systemd unit supervising the container
journalctl -f -u avaslb
⁠Test
curl -v localhost:80
⁠Get status
systemctl status avaslb
⁠Restart container
systemctl restart avaslb
⁠Stop container
systemctl stop avaslb
⁠Start container
systemctl start avaslb
⁠Disable from auto starting
systemctl disable avaslb
⁠Change the Upstream proxies

The upstream proxies are read from the environment variable UPSTREAM_AVAS of which the value is a comma delimited list of ip addresses or hostnames.

  • Edit the environment file: /etc/default/avaslb.env. On the first line you'll see UPSTREAM_AVAS=xxx.xxx.xxx.xxx,xxx.xxx.xxx.xxx,etc.
  • Restart the service: systemctl restart avaslb.
  • Check that the service is running with no errors: systemctl status avaslb
⁠Stats

Goto the following url: http://localhost/basic_status⁠

Credentials:
  user: admin
  pass: <same as docker login>

Stats are really basic on open source nginx and nginx plus is ridiculous. If you need more stats you should use another tool that parses the logs like GoAccess https://goaccess.io/⁠

Tag summary

Content type

Image

Digest

Size

93 MB

Last updated

over 9 years ago

docker pull callforamerica/avaslb