Sign inSign up

labbsr0x/bindman-dns-file-agent

By labbsr0x

•Updated over 6 years ago

Image
0

239

labbsr0x/bindman-dns-file-agent repository overview

⁠labbsr0x/bindman-dns-file-agent

⁠How it works

The bindmand-dns-file-agent is an agent responsible for persisting in bindman-dns-manager by a file.

⁠Contributing

If you find this image useful here's how you can help:

  • Send a pull request with your awesome features and bug fixes
  • Help users resolve their issues⁠.

⁠Issues

Before reporting your issue please try updating Docker to the latest version and check if it resolves the issue. Refer to the Docker installation guide⁠ for instructions.

SELinux users should try disabling SELinux using the command setenforce 0 to see if it resolves the issue.

If the above recommendations do not help then report your issue⁠ along with the following information:

  • Output of the docker version and docker info commands
  • The docker run command or docker-compose.yml used to start the image. Mask out the sensitive bits.

⁠Getting started

⁠Dependencies

bindman-dns-file-agent requires Golang⁠ v1.13, a BIND9 DNS Server⁠ or Dockerize BIND9 DNS Derver⁠ and a bindman-dns-bind9⁠ service to run.

⁠Configurations

Some parameters are required to running the api, these parameters can be passed via the command line or environment variables as described below

ENVCommandRequiredDefaultDescription
BINDMAN_DNS_MANAGER_ADDR-dtruenullBindman DNS Manager Address
BINDMAN_DNS_REVERSE_PROXY_ADDR-rtruenullBindman DNS Reverse Proxy Address
BINDMAN_AGENT_CONFIG_PATH-ctruenullBindman Agent Config Path
BINDMAN_LOG_LEVEL-lfalseinfoSets the Log Level to one of seven (trace, debug, info, warn, error, fatal, panic). Default: info

⁠Installation

Automated builds of the image are available on Dockerhub⁠ and is the recommended method of installation.

docker pull labbsr0x/bindman-dns-file-agent

Alternatively you can build the image yourself.

docker build -t labbsr0x/bindman-dns-file-agent github.com/labbsr0x/bindman-dns-file-agent

or

make build

⁠Quickstart

With all dependencies running, start the agent.

Start BINDMAN-DNS-AGENT-FILE using:

docker run --rm --name bindman-dns-file-agent -d --volume ${PWD}/.agent:/data -e BINDMAN_DNS_MANAGER_ADDR=http://bindman-dns-bind9:7070 -e BINDMAN_DNS_REVERSE_PROXY_ADDR=0.0.0.0 -e BINDMAN_AGENT_CONFIG_PATH=/data/bindman_agent.json --network network-bind labbsr0x/bindman-dns-file-agent

or

make docker-run

Alternatively, you can use the sample docker-compose.yml⁠ file to start the container using Docker Compose⁠

⁠Persistence

For the bindman-dns-file-agent to preserve its state across container shutdown and startup you should mount a volume at /data.

The Quickstart⁠ command already mounts a volume for persistence.

mkdir -p .agent

⁠Maintenance

⁠Upgrading

To upgrade to newer releases:

  1. Download the updated Docker image:
docker pull labbsr0x/bindman-dns-file-agent
  1. Stop the currently running image:
docker stop bindman-dns-file-agent

or

make docker-stop
  1. Remove the stopped container
docker rm labbsr0x/bindman-dns-file-agent

and

rm -rf .agent
  1. Start the updated image
docker run -name bindman-dns-file-agent -d \
  [OPTIONS] \
  labbsr0x/bindman-dns-file-agent

⁠Shell Access

For debugging and maintenance purposes you may want access the containers shell. If you are using Docker version 1.3.0 or higher you can access a running containers shell by starting bash using docker exec:

docker exec -it bindman-dns-file-agent sh

or

make docker-exec

⁠How to run with GO

With all dependencies running, start the agent.

Run in localhost

$ go run main.go agent \
-d=bindman-dns-bind9:7070 \
-r=0.0.0.0 \
-c=bindman_agent.json

For production environments

$ go run main.go agent
$ ENV BINDMAN_DNS_MANAGER_ADDR="bindman-dns-bind9:7070"
$ ENV BINDMAN_DNS_REVERSE_PROXY_ADDR="0.0.0.0"
$ ENV BINDMAN_AGENT_CONFIG_PATH="bindman_agent.json"

Tag summary

Content type

Image

Digest

Size

10.8 MB

Last updated

over 6 years ago

docker pull labbsr0x/bindman-dns-file-agent