8000 feat(ci): add bind9 in automated dnstap test by dmachard · Pull Request #995 · dmachard/DNS-collector · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat(ci): add bind9 in automated dnstap test #995

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
May 1, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion .github/workflows/testing-dnstap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ jobs:
- { service: "dnsdist2", version: "20", mode: "tcp" }
- { service: "dnsdist2", version: "20", mode: "doq" }
- { service: "knotresolver", version: "6.0.11", mode: "unix" }
- { service: "bind9", version: "9.18.33-r0", mode: "unix" }

steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -96,14 +97,17 @@ jobs:
- name: Set environment variable for knotresolver
if: ${{ matrix.config.service == 'knotresolver' }}
run: echo "COLLECTOR_USER=root" >> $GITHUB_ENV
- name: Set environment variable for bind9
if: ${{ matrix.config.service == 'bind9' }}
run: echo "COLLECTOR_USER=runneradmin" >> $GITHUB_ENV

- name: Add pdns user for unix socket test
run: |
sudo addgroup --system --gid 953 pdns
sudo adduser --system --disabled-password --no-create-home -uid 953 --gid 953 pdns
sudo mkdir -p /tmp/dnstap-socket
sudo chmod 777 /tmp/dnstap-socket

- name: Deploy docker image for "${{ matrix.config.service }}"
run: |
case ${{ matrix.config.service }} in
Expand All @@ -122,6 +126,9 @@ jobs:
"knotresolver")
sudo docker run -d --network="host" --name=dnsserver --volume=$PWD/tests/testsdata/knot/knotresolver_${{ matrix.config.mode }}.yml:/etc/knot-resolver/config.yaml:z -v /tmp/dnstap-socket/:/tmp/ cznic/knot-resolver:v${{ matrix.config.version }}
;;
"bind9")
sudo docker run -d --network="host" --name=dnsserver --volume=$PWD/tests/testsdata/bind/bind9_${{ matrix.config.mode }}.conf:/etc/bind/named.conf:z -v /tmp/dnstap-socket/:/tmp/ dmachard/bind9:${{ matrix.config.version }}
;;
esac
until (dig -p 5553 www.github.com @127.0.0.1 | grep NOERROR); do sleep 5.0; done

Expand Down
23 changes: 11 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,17 @@
> - IPv4/v6 defragmentation and TCP reassembly
> - Nanoseconds in timestamps

> The following DNS servers are automatically tested in CI to verify `DNS-collector` compatibility
> with various DNS servers using [dnstap](https://dnstap.info/).
> | DNS Server | Versions Tested | Modes Tested |
> |----------------|---------------------|---------------------|
> | ✅ **Unbound** | 1.22.x, 1.21.x | TCP |
> | ✅ **CoreDNS** | 1.12.1, 1.11.1 | TCP, TLS |
> | ✅ **PowerDNS DNSdist** | 2.0.x, 1.9.x, 1.8.x, 1.7.x | TCP, Unix |
> | ✅ **Knot Resolver** | 6.0.11 | Unix |
> | ✅ **Bind** | 9.18.33 | Unix |


## Features

- **[Pipelining](./docs/running_mode.md)**
Expand Down Expand Up @@ -147,22 +158,10 @@ A [build-in](./docs/dashboards/grafana_exporter.json) dashboard is available for

![dashboard](docs/_images/dashboard_global.png)

## Tested Configurations

The following configurations are automatically tested in CI to verify `DNS-collector` compatibility with various DNS servers using **dnstap**.

| DNS Server | Versions Tested | Modes Tested |
|----------------|---------------------|---------------------|
| **Unbound** | 1.22.x, 1.21.x | TCP |
| **CoreDNS** | 1.12.1, 1.11.1 | TCP, TLS |
| **DNSdist** | 2.0.x, 1.9.x, 1.8.x, 1.7.x | TCP, Unix |
| **Knot Resolver** | 6.0.11 | Unix |

## Contributing

See the [development guide](./docs/development.md) for more information on how to build it yourself.
< 8000 /td>

## More DNS tools ?

| | |
Expand Down
34 changes: 34 additions & 0 deletions tests/testsdata/bind/bind9_unix.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
options {
directory "/var/bind";

listen-on port 5553 { any; };
listen-on-v6 { none; };

allow-query { any; };
allow-transfer { none; };

allow-recursion { any; };
recursion yes;

dnstap { client; auth; resolver; forwarder; };
dnstap-output unix "/tmp/dnstap.sock";
};

zone "." {
type hint;
file "named.ca";
};

zone "localhost" IN {
type master;
file "pri/localhost.zone";
allow-update { none; };
notify no;
};

zone "127.in-addr.arpa" IN {
type master;
file "pri/127.z 40BB one";
allow-update { none; };
notify no;
};
0