Commit 3c6a1e24 authored by Petr Špaček's avatar Petr Špaček

Accept variable overrides in *_run.sh scripts

This is useful for other testing tools which can place binaries in weird
locations etc.
parent d31063bf
...@@ -60,18 +60,18 @@ ...@@ -60,18 +60,18 @@
# Path to scenario files # Path to scenario files
TESTS=sets/resolver TESTS=${TESTS:-"sets/resolver"}
# Path to daemon # Path to daemon
DAEMON=getdns_query DAEMON=${DAEMON:-"getdns_query"}
# Template file name # Template file name
TEMPLATE=template/getdns.j2:template/dnssec_getdns.j2 TEMPLATE=${TEMPLATE:-"template/getdns.j2:template/dnssec_getdns.j2"}
# Config file name # Config file name
CONFIG=getdns.conf:getdns-root.key CONFIG=${CONFIG:-"getdns.conf:getdns-root.key"}
ADDITIONAL="-C getdns.conf" ADDITIONAL=${ADDITIONAL:-"-C getdns.conf"}
export TESTS DAEMON TEMPLATE CONFIG ADDITIONAL export TESTS DAEMON TEMPLATE CONFIG ADDITIONAL
......
#!/bin/bash #!/bin/bash
# Path to scenario files # Path to scenario files
TESTS=sets/knotd/master TESTS=${TESTS:-"sets/knotd/master"}
# Path to daemon # Path to daemon
DAEMON=knotd DAEMON=${DAEMON:-"knotd"}
# Template file name # Template file name
TEMPLATE=template/knotd_master.j2 TEMPLATE=${TEMPLATE:-"template/knotd_master.j2"}
# Config file name # Config file name
CONFIG=knotd.conf CONFIG=${CONFIG:-"knotd.conf"}
# Additional parameter for knotd # Additional parameter for knotd
# it means configuration file can be found in working directory # it means configuration file can be found in working directory
ADDITIONAL="-c ./knotd.conf" ADDITIONAL=${ADDITIONAL:-"-c ./knotd.conf"}
export TESTS DAEMON TEMPLATE CONFIG ADDITIONAL export TESTS DAEMON TEMPLATE CONFIG ADDITIONAL
echo 'INFO: Tests require Knot compiled with ./configure --enable-recvmmsg=no' echo 'INFO: Tests require Knot compiled with ./configure --enable-recvmmsg=no
MAKEDIR="$(dirname "$(readlink -f "$0")")" MAKEDIR="$(dirname "$(readlink -f "$0")")"
make -C "${MAKEDIR}" make -C "${MAKEDIR}"
#!/bin/bash #!/bin/bash
# Path to scenario files # Path to scenario files
TESTS=sets/knotd/slave TESTS=${TESTS:-"sets/knotd/slave"}
# Path to daemon # Path to daemon
DAEMON=knotd DAEMON=${DAEMON:-"knotd"}
# Template file name # Template file name
TEMPLATE=template/knotd_slave.j2 TEMPLATE=${TEMPLATE:-"template/knotd_slave.j2"}
# Config file name # Config file name
CONFIG=knotd.conf CONFIG=${CONFIG:-"knotd.conf"}
# Additional parameter for knotd # Additional parameter for knotd
# it means configuration file can be found in working directory # it means configuration file can be found in working directory
ADDITIONAL="-c ./knotd.conf" ADDITIONAL=${ADDITIONAL:-"-c ./knotd.conf"}
export TESTS DAEMON TEMPLATE CONFIG ADDITIONAL export TESTS DAEMON TEMPLATE CONFIG ADDITIONAL
echo 'INFO: Tests require Knot compiled with ./configure --enable-recvmmsg=no' echo 'INFO: Tests require Knot compiled with ./configure --enable-recvmmsg=no
MAKEDIR="$(dirname "$(readlink -f "$0")")" MAKEDIR="$(dirname "$(readlink -f "$0")")"
make -C "${MAKEDIR}" make -C "${MAKEDIR}"
#!/bin/bash #!/bin/bash
set -o nounset
# Path to scenario files # Path to scenario files
TESTS=sets/resolver TESTS=${TESTS:-"sets/resolver"}
# Path to daemon # Path to daemon
DAEMON=kresd DAEMON=${DAEMON:-"kresd"}
# Template file name # Template file name
TEMPLATE=template/kresd.j2 TEMPLATE=${TEMPLATE:-"template/kresd.j2"}
# Config file name # Config file name
CONFIG=config CONFIG=${CONFIG:-"config"}
export TESTS DAEMON TEMPLATE CONFIG export TESTS DAEMON TEMPLATE CONFIG
......
#!/bin/bash #!/bin/bash
# Path to scenario files # Path to scenario files
TESTS=sets/resolver TESTS=${TESTS:-"sets/resolver"}
# Path to daemon # Path to daemon
DAEMON=$HOME/src/PowerDNS/pdns/pdns/recursordist/pdns_recursor DAEMON=${DAEMON:-"$HOME/src/PowerDNS/pdns/pdns/recursordist/pdns_recursor"}
# Template file name # Template file name
TEMPLATE=template/recursor.j2:template/hints_pdns.j2:template/dnssec_pdns.j2 TEMPLATE=${TEMPLATE:-"template/recursor.j2:template/hints_pdns.j2:template/dnssec_pdns.j2"}
# Config file name # Config file name
CONFIG=recursor.conf:hints.pdns:dnssec.lua CONFIG=${CONFIG:-"recursor.conf:hints.pdns:dnssec.lua"}
# Additional parameter for pdns_recursor # Additional parameter for pdns_recursor
# it means configuration file can be found in working directory # it means configuration file can be found in working directory
ADDITIONAL=--config-dir=./ ADDITIONAL=${ADDITIONAL:-"--config-dir=./"}
export TESTS DAEMON TEMPLATE CONFIG ADDITIONAL export TESTS DAEMON TEMPLATE CONFIG ADDITIONAL
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment