pi-hole-ftl
This commit is contained in:
parent
d6076baa8c
commit
d991dbebeb
7 changed files with 212 additions and 0 deletions
39
pi-hole-ftl/.SRCINFO
Normal file
39
pi-hole-ftl/.SRCINFO
Normal file
|
@ -0,0 +1,39 @@
|
|||
pkgbase = pi-hole-ftl
|
||||
pkgdesc = The Pi-hole FTL engine
|
||||
pkgver = 5.14
|
||||
pkgrel = 1
|
||||
url = https://github.com/pi-hole/FTL
|
||||
install = pi-hole-ftl.install
|
||||
arch = i686
|
||||
arch = x86_64
|
||||
arch = arm
|
||||
arch = armv6h
|
||||
arch = armv7h
|
||||
arch = aarch64
|
||||
license = EUPL-1.2
|
||||
makedepends = cmake
|
||||
makedepends = sqlite
|
||||
depends = nettle
|
||||
depends = gmp
|
||||
depends = libidn
|
||||
depends = readline
|
||||
provides = dnsmasq
|
||||
conflicts = dnsmasq
|
||||
backup = etc/pihole/pihole-FTL.conf
|
||||
backup = etc/pihole/pihole-FTL.db
|
||||
source = pi-hole-ftl-v5.14.tar.gz::https://github.com/pi-hole/FTL/archive/v5.14.tar.gz
|
||||
source = arch-ftl-5.14-124399655.patch::https://raw.githubusercontent.com/max72bra/pi-hole-ftl-archlinux-customization/master/arch-ftl-5.14.patch
|
||||
source = pi-hole-ftl.tmpfile
|
||||
source = pi-hole-ftl.sysuser
|
||||
source = pi-hole-ftl.service
|
||||
source = pi-hole-ftl.db
|
||||
source = pi-hole-ftl.conf
|
||||
sha256sums = 351efed2624e82baf6ddcf76face610bfb0e9ff87f8fa3d89ad30c0f8684d264
|
||||
sha256sums = b8bde48093ebf8429e5769eacc5351c47d5d3bd73850089b39cbec13334aac42
|
||||
sha256sums = 538d2f66e30eabeeb0ac6794ac388b96ddf1830d9e988a0aaa810cb17c5c69fc
|
||||
sha256sums = 39ef7bfd672ce59440bbf89e812992adc4d40091bc8d70fa24bd586381979064
|
||||
sha256sums = 7f9ed05cec17c483077c0f14fecc5b7555bd4eeb0d8898a4f0c8b878fc82c9d6
|
||||
sha256sums = 8beb120ac275f88c4b72bf2dde583f27f0c1e1fb9766c2d7c60285bd342867ed
|
||||
sha256sums = bd4794a73bea22f3301cf6ab8d9029d8e671e6411a26493a2ffbdf462129268c
|
||||
|
||||
pkgname = pi-hole-ftl
|
61
pi-hole-ftl/PKGBUILD
Normal file
61
pi-hole-ftl/PKGBUILD
Normal file
|
@ -0,0 +1,61 @@
|
|||
# Contributor: Mettacrawer <metta.crawler@gmail.com>
|
||||
# Contributor: luizribeiro <luizribeiro@gmail.com>
|
||||
# Maintainer: max.bra <max dot bra dot gtalk at gmail dot com>
|
||||
# Maintainer: graysky <graysky AT archlinux DOT us>
|
||||
|
||||
pkgname=pi-hole-ftl
|
||||
_pkgname=FTL
|
||||
_servicename=pihole-FTL
|
||||
pkgver=5.14
|
||||
pkgrel=1
|
||||
_now=`date +%N`
|
||||
arch=('i686' 'x86_64' 'arm' 'armv6h' 'armv7h' 'aarch64')
|
||||
pkgdesc="The Pi-hole FTL engine"
|
||||
url="https://github.com/pi-hole/FTL"
|
||||
license=('EUPL-1.2')
|
||||
depends=('nettle' 'gmp' 'libidn' 'readline')
|
||||
makedepends=('cmake' 'sqlite')
|
||||
conflicts=('dnsmasq')
|
||||
provides=('dnsmasq')
|
||||
install=$pkgname.install
|
||||
backup=('etc/pihole/pihole-FTL.conf' 'etc/pihole/pihole-FTL.db')
|
||||
source=($pkgname-v$pkgver.tar.gz::"https://github.com/pi-hole/FTL/archive/v$pkgver.tar.gz"
|
||||
arch-ftl-$pkgver-$_now.patch::"https://raw.githubusercontent.com/max72bra/pi-hole-ftl-archlinux-customization/master/arch-ftl-$pkgver.patch"
|
||||
"$pkgname.tmpfile"
|
||||
"$pkgname.sysuser"
|
||||
"$pkgname.db"
|
||||
"$pkgname.conf")
|
||||
sha256sums=('351efed2624e82baf6ddcf76face610bfb0e9ff87f8fa3d89ad30c0f8684d264'
|
||||
'b8bde48093ebf8429e5769eacc5351c47d5d3bd73850089b39cbec13334aac42'
|
||||
'538d2f66e30eabeeb0ac6794ac388b96ddf1830d9e988a0aaa810cb17c5c69fc'
|
||||
'39ef7bfd672ce59440bbf89e812992adc4d40091bc8d70fa24bd586381979064'
|
||||
'8beb120ac275f88c4b72bf2dde583f27f0c1e1fb9766c2d7c60285bd342867ed'
|
||||
'bd4794a73bea22f3301cf6ab8d9029d8e671e6411a26493a2ffbdf462129268c')
|
||||
|
||||
prepare() {
|
||||
cd "$srcdir"/"$_pkgname"-"$pkgver"
|
||||
patch -Np1 -i "$srcdir"/arch-ftl-$pkgver-$_now.patch
|
||||
}
|
||||
|
||||
build() {
|
||||
cd "$srcdir"/"$_pkgname"-"$pkgver"
|
||||
./build.sh
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "$srcdir"
|
||||
install -Dm775 "$_pkgname"-$pkgver/pihole-FTL "${pkgdir}"/usr/bin/pihole-FTL
|
||||
|
||||
install -Dm644 "$pkgname.tmpfile" "$pkgdir"/usr/lib/tmpfiles.d/$pkgname.conf
|
||||
install -Dm644 "$pkgname.sysuser" "$pkgdir"/usr/lib/sysusers.d/$pkgname.conf
|
||||
|
||||
install -dm775 "$pkgdir"/etc/pihole
|
||||
install -Dm644 "$pkgname.conf" "$pkgdir"/etc/pihole/pihole-FTL.conf
|
||||
install -Dm644 "$pkgname.db" "$pkgdir"/etc/pihole/pihole-FTL.db
|
||||
|
||||
install -dm755 "$pkgdir"/usr/share/licenses/pihole
|
||||
install -Dm644 "$_pkgname"-$pkgver/LICENSE "$pkgdir"/usr/share/licenses/pihole/Pi-hole-FTL
|
||||
|
||||
# ver. 5.0 dnamasq dropin support
|
||||
ln -s ./pihole-FTL "$pkgdir/usr/bin/dnsmasq"
|
||||
}
|
90
pi-hole-ftl/pi-hole-ftl.conf
Normal file
90
pi-hole-ftl/pi-hole-ftl.conf
Normal file
|
@ -0,0 +1,90 @@
|
|||
### This file contains parameters for FTL behavior.
|
||||
### At install, all parameters are commented out. The user can select desired options.
|
||||
### Options shown are the default configuration. No modification is needed for most
|
||||
### installations.
|
||||
### Visit https://docs.pi-hole.net/ftldns/configfile/ for more detailed parameter explanations
|
||||
|
||||
## Out of documentation
|
||||
#LOGFILE=/run/log/pihole-ftl/pihole-FTL.log
|
||||
#PIDFILE=/run/pihole-ftl/pihole-FTL.pid
|
||||
#PORTFILE=/run/pihole-ftl/pihole-FTL.port
|
||||
#SOCKETFILE=/run/pihole-ftl/FTL.sock
|
||||
|
||||
## Socket Listening
|
||||
## Listen only for local socket connections or permit all connections
|
||||
## Options: localonly, all
|
||||
#SOCKET_LISTENING=localonly
|
||||
|
||||
## Query Display
|
||||
## Display all queries? Set to no to hide query display
|
||||
## Options: yes, no
|
||||
#QUERY_DISPLAY=yes
|
||||
|
||||
## AAA Query Analysis
|
||||
## Allow FTL to analyze AAAA queries from pihole.log?
|
||||
## Options: yes, no
|
||||
#AAAA_QUERY_ANALYSIS=yes
|
||||
|
||||
## Resolve IPv6
|
||||
## Should FTL try to resolve IPv6 addresses to host names?
|
||||
## Options: yes, no
|
||||
#RESOLVE_IPV6=yes
|
||||
|
||||
## Resolve IPv4
|
||||
## Should FTL try to resolve IPv4 addresses to host names?
|
||||
## Options: yes, no
|
||||
#RESOLVE_IPV4=yes
|
||||
|
||||
## Max Database Days
|
||||
## How long should queries be stored in the database -days-?
|
||||
## Setting this to 0 disables the database
|
||||
## See: https://docs.pi-hole.net/ftldns/database/
|
||||
## Options: number of days
|
||||
#MAXDBDAYS=365
|
||||
|
||||
## Database Interval
|
||||
## How often do we store queries in FTL's database -minutes-?
|
||||
## See: https://docs.pi-hole.net/ftldns/database/
|
||||
## Options: number of minutes
|
||||
#DBINTERVAL=1.0
|
||||
|
||||
## Database File
|
||||
## Specify path and filename of FTL's SQLite3 long-term database.
|
||||
## Setting this to DBFILE= disables the database altogether
|
||||
## See: https://docs.pi-hole.net/ftldns/database/
|
||||
## Option: path to db file
|
||||
#DBFILE=/etc/pihole/pihole-FTL.db
|
||||
|
||||
## Max Log Age
|
||||
## Up to how many hours of queries should be imported from the database and logs -hours-?
|
||||
## Maximum is 744 -31 days-
|
||||
## Options: number of days
|
||||
#MAXLOGAGE=24.0
|
||||
|
||||
## FTL Port
|
||||
## On which port should FTL be listening?
|
||||
## Options: tcp port
|
||||
#FTLPORT=4711
|
||||
|
||||
## Privacy Level
|
||||
## Which privacy level is used?
|
||||
## See: https://docs.pi-hole.net/ftldns/privacylevels/
|
||||
## Options: 0, 1, 2, 3
|
||||
#PRIVACYLEVEL=0
|
||||
|
||||
## Ignore Localhost
|
||||
## Should FTL ignore queries coming from the local machine?
|
||||
## Options: yes, no
|
||||
#IGNORE_LOCALHOST=no
|
||||
|
||||
## Blocking Mode
|
||||
## How should FTL reply to blocked queries?
|
||||
## See: https://docs.pi-hole.net/ftldns/blockingmode/
|
||||
## Options: NULL, IP-NODATA-AAAA, IP, NXDOMAIN
|
||||
#BLOCKINGMODE=NULL
|
||||
|
||||
## Regex Debug Mode
|
||||
## Controls if FTLDNS should print extended details about regex matching into pihole-FTL.log.
|
||||
## See: https://docs.pi-hole.net/ftldns/regex/overview/
|
||||
## Options: true, false
|
||||
#REGEX_DEBUGMODE=false
|
BIN
pi-hole-ftl/pi-hole-ftl.db
Normal file
BIN
pi-hole-ftl/pi-hole-ftl.db
Normal file
Binary file not shown.
15
pi-hole-ftl/pi-hole-ftl.install
Normal file
15
pi-hole-ftl/pi-hole-ftl.install
Normal file
|
@ -0,0 +1,15 @@
|
|||
post_install() {
|
||||
# ftl DB permissions
|
||||
#[ -e /etc/pihole/pihole-FTL.db ] && chown pihole.pihole /etc/pihole /etc/pihole/pihole-FTL.db
|
||||
|
||||
echo -e "\e[1;33m==>\e[0m Possible configurations in \e[1;31m/etc/pihole/pihole-FTL.conf\e[0m file"
|
||||
echo -e "\e[1;33m==>\e[0m Please read the instructions on the project page: \e[1;36mhttps://docs.pi-hole.net/ftldns/configfile/\e[0m"
|
||||
}
|
||||
|
||||
post_upgrade() {
|
||||
post_install $1
|
||||
}
|
||||
|
||||
post_remove() {
|
||||
id -u pihole > /dev/null 2>&1 && userdel -f pihole
|
||||
}
|
2
pi-hole-ftl/pi-hole-ftl.sysuser
Normal file
2
pi-hole-ftl/pi-hole-ftl.sysuser
Normal file
|
@ -0,0 +1,2 @@
|
|||
u pihole - "pihole daemon" /
|
||||
m http pihole
|
5
pi-hole-ftl/pi-hole-ftl.tmpfile
Normal file
5
pi-hole-ftl/pi-hole-ftl.tmpfile
Normal file
|
@ -0,0 +1,5 @@
|
|||
d /run/log/pihole-ftl 0755 pihole pihole - -
|
||||
f /run/log/pihole-ftl/pihole-FTL.log 0644 pihole pihole - -
|
||||
d /run/pihole-ftl 0755 pihole pihole - -
|
||||
f /run/pihole-ftl/pihole-FTL.pid 0644 pihole pihole - -
|
||||
f /run/pihole-ftl/pihole-FTL.port 0644 pihole pihole - -
|
Loading…
Reference in a new issue