RESOLVERIP=127.0.0.1 \
./start-test-stop 5300 << parameters.context >>
- install-recursor-deps:
- description: "Install all libraries needed for the recursor"
- steps:
- - run: apt-get update
- - run:
- command: |
- apt-get install -qq -y \
- libluajit-5.1-2 \
- libboost-all-dev \
- libcap2 \
- libssl1.1 \
- libsystemd0 \
- libsodium23 \
- libfstrm0 \
- libsnmp30
-
install-auth-deps:
description: Install all libraries needed to run the auth
steps:
context: geoip
doroot: false
- build-recursor:
- docker:
- - image: debian:buster
- auth:
- username: powerdnsreadonly
- password: $DOCKERHUB_PASSWORD
- environment:
- UBSAN_OPTIONS: 'print_stacktrace=1:halt_on_error=1'
- ASAN_OPTIONS: detect_leaks=0
- steps:
- - run:
- name: Install dependencies
- command: |
- apt-get update && apt-get -qq --no-install-recommends install \
- autoconf \
- automake \
- ca-certificates \
- curl \
- bison \
- flex \
- g++ \
- git \
- libboost-all-dev \
- libcap-dev \
- libluajit-5.1-dev \
- libfstrm-dev \
- libsnmp-dev \
- libsodium-dev \
- libssl-dev \
- libsystemd-dev \
- libtool \
- make \
- pkg-config \
- ragel \
- systemd \
- python3-venv
- - install-clang-8
- - restore-cache-ccache:
- product: recursor
- - get-workspace
- - run:
- name: autoconf
- command: BUILDER_VERSION=0.0.0-git1 autoreconf -vfi
- working_directory: ~/project/pdns/recursordist
- - run:
- name: configure
- command: |
- CC='clang-8' \
- CXX='clang++-8' \
- CFLAGS="-O1 -Werror=vla -Werror=shadow -Wformat=2 -Werror=format-security -Werror=string-plus-int" \
- CXXFLAGS="-O1 -Werror=vla -Werror=shadow -Wformat=2 -Werror=format-security -Werror=string-plus-int -Wp,-D_GLIBCXX_ASSERTIONS" \
- ./configure \
- --enable-option-checking=fatal \
- --enable-unit-tests \
- --enable-nod \
- --enable-systemd \
- --prefix=/opt/pdns-recursor \
- --with-libsodium \
- --with-lua=luajit \
- --with-libcap \
- --with-net-snmp \
- --enable-dns-over-tls \
- --enable-asan \
- --enable-ubsan
- working_directory: ~/project/pdns/recursordist
- - run:
- name: build
- command: make -j3 -k
- working_directory: ~/project/pdns/recursordist
- - save-ccache-cache:
- product: recursor
- - run:
- name: Run unit tests
- command: make check || (cat test-suite.log; false)
- working_directory: ~/project/pdns/recursordist
- - run:
- name: Install resulting binaries
- command: make install
- working_directory: ~/project/pdns/recursordist
- - persist_to_workspace:
- root: /opt
- paths:
- - pdns-recursor
-
- test-recursor-regression:
- resource_class: small
-
- docker:
- - image: debian:buster
- auth:
- username: powerdnsreadonly
- password: $DOCKERHUB_PASSWORD
- environment:
- UBSAN_OPTIONS: 'print_stacktrace=1:halt_on_error=1'
- ASAN_OPTIONS: detect_leaks=0
- steps:
- - add-auth-repo
- - run: apt-get --no-install-recommends install -qq -y pdns-server pdns-backend-bind pdns-tools daemontools authbind jq libfaketime lua-posix lua-socket moreutils bc python3-venv protobuf-compiler prometheus
- - install-recursor-deps
- - run:
- name: Set up authbind
- command: |
- touch /etc/authbind/byport/53
- chmod 755 /etc/authbind/byport/53
- - get-workspace
- - run:
- name: setup snmp
- command: |
- apt-get -qq --no-install-recommends install snmpd
- sed "s/agentxperms 0700 0755 recursor/agentxperms 0700 0755/g" regression-tests.recursor-dnssec/snmpd.conf > /etc/snmp/snmpd.conf
- /etc/init.d/snmpd start
- - run:
- name: Run regression tests
- workdir: ~/project
- command: |
- PDNSRECURSOR=/opt/pdns-recursor/sbin/pdns_recursor \
- RECCONTROL=/opt/pdns-recursor/bin/rec_control \
- SKIP_IPV6_TESTS=y \
- ./build-scripts/test-recursor
-
- test-recursor-bulk:
- resource_class: medium
-
- docker:
- - image: debian:buster
- auth:
- username: powerdnsreadonly
- password: $DOCKERHUB_PASSWORD
- environment:
- UBSAN_OPTIONS: 'print_stacktrace=1:halt_on_error=1'
- ASAN_OPTIONS: detect_leaks=0
- steps:
- - add-auth-repo
- - run: apt-get --no-install-recommends install -qq -y pdns-tools moreutils time
- - install-recursor-deps
- - get-workspace
- - run:
- name: Get the majestic million list
- workdir: ~/project/regression-tests
- command: |
- apt-get install -qq -y unzip && \
- curl -LO http://s3-us-west-1.amazonaws.com/umbrella-static/top-1m.csv.zip && \
- unzip top-1m.csv.zip -d .
- - run:
- name: Run bulktest A
- command: |
- DNSBULKTEST=/usr/bin/dnsbulktest \
- RECURSOR=/opt/pdns-recursor/sbin/pdns_recursor \
- RECCONTROL=/opt/pdns-recursor/bin/rec_control \
- THRESHOLD=95 \
- TRACE=no \
- ./timestamp ./recursor-test 5300 50000 2
- workdir: ~/project/regression-tests
- - run:
- name: Run bulktest B
- command: |
- DNSBULKTEST=/usr/bin/dnsbulktest \
- RECURSOR=/opt/pdns-recursor/sbin/pdns_recursor \
- RECCONTROL=/opt/pdns-recursor/bin/rec_control \
- THRESHOLD=95 \
- TRACE=no \
- ./timestamp ./recursor-test 5300 50000 4
- workdir: ~/project/regression-tests
- - run:
- name: Run bulktest C
- command: |
- DNSBULKTEST=/usr/bin/dnsbulktest \
- RECURSOR=/opt/pdns-recursor/sbin/pdns_recursor \
- RECCONTROL=/opt/pdns-recursor/bin/rec_control \
- THRESHOLD=95 \
- TRACE=no \
- ./timestamp ./recursor-test 5300 50000 8
- workdir: ~/project/regression-tests
- - run:
- name: Run bulktest D
- command: |
- DNSBULKTEST=/usr/bin/dnsbulktest \
- RECURSOR=/opt/pdns-recursor/sbin/pdns_recursor \
- RECCONTROL=/opt/pdns-recursor/bin/rec_control \
- THRESHOLD=95 \
- TRACE=no \
- ./timestamp ./recursor-test 5300 50000 16
- workdir: ~/project/regression-tests
-
build-auth-docs:
resource_class: small
- test-auth-regress-ldap:
requires:
- build-auth
- - build-recursor:
- requires:
- - checkout
- - test-recursor-regression:
- requires:
- - build-recursor
- - test-recursor-bulk:
- requires:
- - build-recursor
build-docs:
jobs: