mirror of
https://github.com/pi-hole/FTL.git
synced 2025-12-20 04:18:25 +00:00
@@ -19,6 +19,10 @@
|
||||
#include "dnsmasq.h"
|
||||
#include <setjmp.h>
|
||||
|
||||
/* Pi-hole modification */
|
||||
#include "../version.h"
|
||||
/************************/
|
||||
|
||||
static volatile int mem_recover = 0;
|
||||
static jmp_buf mem_jmp;
|
||||
static int one_file(char *file, int hard_opt);
|
||||
@@ -4772,6 +4776,9 @@ void read_opts(int argc, char **argv, char *compile_opts)
|
||||
add_txt("privacylevel.pihole", NULL, TXT_PRIVACYLEVEL);
|
||||
/************************/
|
||||
#endif
|
||||
/******** Pi-hole modification ********/
|
||||
add_txt("version.FTL", GIT_VERSION, 0 );
|
||||
/**************************************/
|
||||
|
||||
while (1)
|
||||
{
|
||||
|
||||
13
test/run.sh
13
test/run.sh
@@ -6,13 +6,16 @@ if [[ "${1}" != "pihole-FTL-linux-x86_64" ]]; then
|
||||
fi
|
||||
|
||||
# Install necessary additional components for testing
|
||||
apt install dns-utils
|
||||
apt install dnsutils -y
|
||||
|
||||
# Create necessary directories
|
||||
mkdir -p /etc/pihole /var/run/pihole /var/log
|
||||
|
||||
# We cannot bind to port
|
||||
echo "port=50" > /etc/dnsmasq.conf
|
||||
|
||||
# Start FTL
|
||||
./pihole-FTL
|
||||
project/pihole-FTL-linux-x86_64
|
||||
|
||||
# Prepare BATS
|
||||
mkdir -p test/libs
|
||||
@@ -23,6 +26,12 @@ git submodule add https://github.com/ztombol/bats-support test/libs/bats-support
|
||||
# Block until FTL is ready, retry once per second for 45 seconds
|
||||
sleep 2
|
||||
|
||||
# Print versions of pihole-FTL
|
||||
echo "FTL version:"
|
||||
dig TXT CHAOS version.FTL @127.0.0.1 +short
|
||||
echo "Contained dnsmasq version:"
|
||||
dig TXT CHAOS version.bind @127.0.0.1 +short
|
||||
|
||||
# Print content of pihole-FTL.log
|
||||
cat /var/log/pihole-FTL.log
|
||||
|
||||
|
||||
Reference in New Issue
Block a user