1
0
mirror of https://github.com/pi-hole/pi-hole synced 2024-11-18 22:28:18 +00:00
Commit Graph

1313 Commits

Author SHA1 Message Date
Adam Warner
e393048488
Merge pull request #4229 from MichaIng/patch-3
Hardcode whiptail dimensions to 20 rows and 70 chars width
2021-09-11 21:37:14 +01:00
Adam Warner
89e187947e
Merge pull request #4282 from pi-hole/new/RFC6761
Install RFC6761 config file
2021-09-11 20:44:46 +01:00
Christian König
839a70cc37 Add sudo to apt-get recommendation
Signed-off-by: Christian König <ckoenig@posteo.de>
2021-08-27 19:16:15 +02:00
DL6ER
ff64d8cf4d
Use variable in user output, too
Signed-off-by: DL6ER <dl6er@dl6er.de>
2021-08-16 09:57:12 +02:00
MichaIng
e1dca46423 Hardcode whiptail dimensions to 20 rows and 70 chars width
With the suggested way to call the installer via "curl -sSL https://install.pi-hole.net | bash", STDIN is no terminal, but overridden by the curl output, hence in most cases, the minimum dimensions were applied, even on larger screens. All whiptail calls are hence assured to work fine with those dimensions, aside of one case, making the calculations obsolete.

This commit hardcodes the whiptail dimensions to the prior minimum and removes the calculations. This also helps with testing, as it does not matter anymore how the script is called, and developers have a clearly defined space to make dialogs look nice, including line breaks, menu and list heights.

The only case which does not fit the 70 character width, the second menu entry of the "pihole -r" dialog, has been shortened accordingly. This was not an issue before, as "pihole -r" does not override the scripts STDIN and hence did allow larger dimensions based on the now removed calculations.

See the following discussions for reference:
- https://github.com/pi-hole/pi-hole/issues/3323
- https://github.com/pi-hole/pi-hole/pull/4197#issuecomment-876702380

Signed-off-by: MichaIng <micha@dietpi.com>
2021-08-15 18:04:11 +02:00
DL6ER
ea5a3bf0b2
Install RFC6761 config file
Signed-off-by: DL6ER <dl6er@dl6er.de>
2021-08-15 11:21:24 +02:00
Adam Warner
bdab701470
Remove dhcpcd5 dependency, however still help the user set the static IP if dhcpd5 is already installed (i.e on raspbian)
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2021-08-05 19:02:37 +01:00
Adam Warner
1ecb9165ee
Remove weird global counter
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2021-08-05 19:02:37 +01:00
Adam Warner
2ff3b95117
put FTL Install back to where it was
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2021-08-05 19:02:37 +01:00
Adam Warner
3ad5097b12
Change initial install script order:
1. Ensure we have a compatible package manager
  2. Install required packages for os_check to run (we need dnsutils and grep for this
  3. Try to install FTL
  4. FTL installed? Install installer dependencies and continue as normal - no other dependencies are installed until user has gone through all whiptails

Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2021-08-05 19:02:37 +01:00
Adam Warner
d68a2ffaf3
Install only minimal requiered package before performing os_check
Co-authored-by: Christian König <ckoenig@posteo.de>
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2021-08-05 19:02:36 +01:00
Adam Warner
913dcead7f
move chmod/chown of macvendor.db to pihole-FTL.service
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2021-08-05 19:02:36 +01:00
Adam Warner
1358209a9a
rename distro_check to package_manager_detect, as it is more in keeping with what the function actually does
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2021-08-05 19:02:36 +01:00
DL6ER
d0eb0d5037
Remove extra failure display when installation of logrotate file is skipped because the file already exists
Signed-off-by: DL6ER <dl6er@dl6er.de>
2021-07-28 21:18:02 +02:00
Dan Schaper
b1ea60484e
Guard for logrotate func non-zero return
Signed-off-by: Dan Schaper <dan.schaper@pi-hole.net>
2021-07-26 13:22:26 -07:00
Daniel
fdca19e66d Support and test Debian Bullsye (11)
Signed-off-by: Daniel <daniel@developerdan.com>
2021-07-07 19:09:54 +00:00
Adam Warner
8c926d6af6
Merge pull request #4158 from MichaIng/patch-2
Remove false statement about dependency removal on Raspbian
2021-07-04 00:43:09 +01:00
Adam Warner
c120f8a8d8
Revert "Include lighttpd-mod-deflate since it is no longer provided by default in Bullsye" 2021-07-02 22:09:41 +01:00
Daniel
2b49988013
Include lighttpd-mod-deflate in the PIHOLE_WEB_DEPS list since it is no longer provided by default in Debian Bullseye
Signed-off-by: Daniel <daniel@developerdan.com>
2021-07-01 02:20:22 +00:00
Dan Schaper
4f660966d0
Shellchecker
Signed-off-by: Dan Schaper <dan.schaper@pi-hole.net>
2021-06-20 11:19:19 -07:00
Dan Schaper
7df22cd8e0
Check for logroate script existing first.
Signed-off-by: Dan Schaper <dan.schaper@pi-hole.net>
2021-06-20 11:18:33 -07:00
MichaIng
c901443676 Remove false statement about dependency removal on Raspbian
The statement "All dependencies are safe to remove on Raspbian" has been added at a time where a much smaller list of dependencies were installed, all indeed relatively safe to purge. Nowadays this list has grown and includes important system packages, like iproute2, psmisc, sudo, curl and others, which are often again dependencies of other packages, like network stacks (ifupdown) and others, so that inexperienced users, following that statement, may break their systems network capabilities and more.

This message has hence been removed.

Signed-off-by: MichaIng <micha@dietpi.com>
2021-05-02 13:29:28 +02:00
MichaIng
f3ceebbe06
Re-remove wget from dependencies
The dependency has been removed here: https://github.com/pi-hole/pi-hole/pull/3185
But accidentally re-added here: 982c1b0059 (diff-595630a29a855f6d667a84ca0662042e826bf3ec56322ef61d4a6ef149147d23)

wget is still not used in any Pi-hole script, hence it can be removed safely from dependencies.

Signed-off-by: MichaIng <micha@dietpi.com>
2021-04-30 20:48:12 +02:00
MichaIng
2ba350984f Enable PHP8 support for Debian/Ubuntu
Since PHP8.0, the JSON extension is a core PHP extension and hence the php8.0-json package does not exist and is not required:
- https://www.php.net/manual/json.installation.php
- https://packages.debian.org/php8.0-json

Solves: https://discourse.pi-hole.net/t/php-8-packages-not-found/46286

Signed-off-by: MichaIng <micha@dietpi.com>
2021-04-18 15:33:05 +02:00
DL6ER
74948ae5c1
The correct port separator is '#' not ':' in dnsmasq style. This should not have been changed in #4083 in the first place.
Signed-off-by: DL6ER <dl6er@dl6er.de>
2021-04-14 22:53:12 +02:00
bcambl
d5f13018a7 Merge branch 'release/v5.3' into fedora_33_support
Signed-off-by: bcambl <blayne@blaynecampbell.com>
2021-04-12 20:06:11 -06:00
jbzdarkid
8090071eff Update regex to disallow leading zeros
Also updated a comment to point to a non-experimental RFC.

Signed-off-by: jbzdarkid <jbzdarkid@gmail.com>
2021-03-21 16:27:08 -07:00
Joseph Blackman
89c80947df Improve regexes for ipv4 matching
Signed-off-by: jbzdarkid <jbzdarkid@gmail.com>
2021-03-21 16:24:35 -07:00
jbzdarkid
20b6f9cceb Improve comments in basic-install.sh
Signed-off-by: jbzdarkid <jbzdarkid@gmail.com>
2021-03-17 18:37:18 -07:00
bcambl
c6810a0124 touch sysconfig network script when absent
sysconfig network scripts are missing on pure NetworkManager installs.
This commit touches a placeholder to allow the network configuration to
be generated and loaded via NetworkManager.

Signed-off-by: bcambl <blayne@blaynecampbell.com>
2021-01-19 23:06:39 -06:00
freddii
7c0c30fb0b fixed typos 2021-01-19 19:33:38 +01:00
Dan Schaper
3f8fedfb16
Revert "Further failsafe check for available APT packages" 2021-01-17 11:10:24 -08:00
Dan Schaper
523f650157
Use the 'Location:' header only.
Signed-off-by: Dan Schaper <dan.schaper@pi-hole.net>
2021-01-12 13:42:51 -08:00
DL6ER
c5ed8f8bed
Merge pull request #3537 from MichaIng/patch-2
Further failsafe check for available APT packages
2021-01-07 11:56:52 +01:00
bcambl
a5422dbdf6 fix release check for centos stream
fixes #3947 #3953

Signed-off-by: bcambl <blayne@blaynecampbell.com>
2020-12-30 19:45:51 -06:00
Christian König
0d710fc9e3 Change wording in whiptail for adlist selection
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-12-24 21:19:14 +01:00
Adam Warner
eb86a5e3b0
Merge pull request #3937 from yubiuser/remove_malwaredomains
Remove deprecated malwaredomains list
2020-12-24 15:24:48 +00:00
Dan Schaper
60fa93ab47
Add fallback for arch detection on i386/x86_64
Signed-off-by: Dan Schaper <dan.schaper@pi-hole.net>
2020-12-23 14:59:28 -08:00
Christian König
b4102547ac Remove deprecated malwaredomains list
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-12-21 13:11:59 +01:00
MichaIng
eb5661b553 Further failsafe check for available APT packages
- "apt-cache show package" succeeds as well if package is listed as (optional) dependency or conflict by another package, hence is not a 100% reliable measure.
- There is no command which explicitly checks which package/name can be selected by apt-get for install. An install simulation/dry-run is possible as it was before Pi-hole v5.1, or the whole package cache can be scraped, which is still the less time consuming solution.
- Allow to succeed if another package "provides" it, like "php7.3-apcu" provided by "php-apcu" or "awk" provided by "mawk" and "gawk", in which case the non-virtual package is selected automatically by apt-get.

For reference: 066b89fa41

Signed-off-by: MichaIng <micha@dietpi.com>
2020-12-18 23:20:24 +01:00
Adam Warner
e47eb30a6e
Update automated install/basic-install.sh
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-12-02 20:49:07 +00:00
Adam Warner
641951b3a0
add some meaningful outputSigned-off-by: Adam Warner <me@adamwarner.co.uk> 2020-12-02 20:40:51 +00:00
Adam Warner
61f13a334d
Don't delete an existing directory and clone our repo in its place. TODO: Something more robust
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-12-02 20:19:59 +00:00
Christian König
0ecb8bf5e9 Add lsof to dependencies for non Debian OS
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-11-29 21:05:40 +01:00
Adam Warner
a8e97257d7
Ensure entries of PIHOLE_DNS_10 and above are not deleted when removing PIHOLE_DNS_1 and PIHOLE_DNS_2
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-11-29 15:08:46 +00:00
Christian König
065e5cb1fe Add DNSSEC to OpenDNS description
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-11-24 21:02:53 +01:00
Adam Warner
541b53229c
Include secondary upstream DNS for Quad9+Filter+ECS
Co-authored-by: Daniel Tulleman <github@be-lumino.us>
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-11-18 22:06:03 +00:00
Grégory Sanchez
e26472756f Merge branch 'development' into fix/unattended_install 2020-11-16 23:33:07 +01:00
Grégory Sanchez
6826d9f316 fix(basic-install): unattended install should finish without interaction
Fixes: https://github.com/pi-hole/pi-hole/issues/3617

Signed-off-by: Grégory Sanchez <gregory.sanchez@icloud.com>
2020-11-16 23:15:02 +01:00
Adam Warner
bd6ca0ad62
Merge pull request #3825 from yubiuser/tweak/cross
Change icon from cross to [i] for root user check
2020-11-15 20:42:05 +00:00
Viet Hung Nguyen
ae4e41eaaa Re-run the script as root instead of piping to bash
Signed-off-by: Viet Hung Nguyen <hvn@familug.org>
2020-10-30 23:53:31 +07:00
Christian König
0ae020ef82 Change icon from cross to [i]# for root user check
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-10-29 20:37:08 +01:00
DL6ER
83f2e2d85a
Merge pull request #3801 from pi-hole/new/armv4_armv5_armv8
Add native ARMv4T, ARMv5TE and ARMv8-A support
2020-10-18 19:53:56 +02:00
DL6ER
01c9bbd3ca
Improve processor detection to use the new dedicated ARMv4T, ARMv5TE and ARMv8-A binaries we provide for FTL.
Signed-off-by: DL6ER <dl6er@dl6er.de>
2020-10-14 20:31:22 +02:00
Adam Warner
59b0a6af6f
Remove references to privacy level 4 (no longer functional)
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-10-13 23:53:23 +01:00
MichaIng
615b19c3d6
web server question enhancements (#3225)
+ Do not ask to install the web server, if the web interface has been deselected before.
+ Add additional info, that PHP modules need to be installed manually, when web server is deselected and the web server user needs to be member of the "pihole" group.
+ Consequently use webroot variable instead of /var/www/html

Signed-off-by: MichaIng <micha@dietpi.com>
2020-10-09 16:12:21 +02:00
Christian König
e9796d5671 Remove traces of previous default adlists
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-09-28 06:15:46 +02:00
Adam Warner
d6c4f0696f
Merge pull request #3698 from yubiuser/remove/FreeSpaceCheck
Remove check for free disk space and associated variables
2020-09-21 08:47:41 +01:00
DirkJanIT
b88510d89a
Add CACHE_SIZE to setupVars (#3170)
* Update 01-pihole.conf

Signed-off-by: DoubleOhmSeven <57564379+DoubleOhmSeven@users.noreply.github.com>

* Update basic-install.sh

Signed-off-by: DoubleOhmSeven <57564379+DoubleOhmSeven@users.noreply.github.com>

Co-authored-by: DoubleOhmSeven <57564379+DoubleOhmSeven@users.noreply.github.com>
2020-09-17 23:13:40 +02:00
Blayne Campbell
4d98e156b6
Merge pull request #3607 from cgzones/selinux
basic-install: document how to continue after SELinux check
2020-09-16 23:54:05 -06:00
Adam Warner
e02cf6fac5
further tweaks, plus a spelling mistake correction
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-08-23 14:50:04 +01:00
Adam Warner
8e219cb799
Make output more meaningful in case of dig failure.
Include dig return code and response in debug run

Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-08-23 10:48:15 +01:00
Christian König
65786ba5d6 Remove check for free disk space and associated variables
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-08-18 20:16:35 +02:00
Adam Warner
42f55f5202
Merge pull request #3688 from pi-hole/tweak/os-check
Tweaks to os_check() Redux
2020-08-17 17:31:58 +01:00
Adam Warner
725f02f442
Merge pull request #3673 from yubiuser/fix/double_check_adlist_not_selected
Revert "fix #3336 by creating adlist file even if no list was selecte…
2020-08-17 17:30:31 +01:00
Dan Schaper
ebdb68a47a
display_warning fixes
Signed-off-by: Dan Schaper <dan.schaper@pi-hole.net>
2020-08-15 10:54:31 -07:00
Dan Schaper
623ce1fe18
Tabs and debug.sh
Signed-off-by: Dan Schaper <dan.schaper@pi-hole.net>
2020-08-14 14:37:58 -07:00
Dan Schaper
57e65dd5c0
Use fewer subshells and descriptive variables.
Signed-off-by: Dan Schaper <dan.schaper@pi-hole.net>
2020-08-14 11:42:54 -07:00
Adam Warner
bb1a6243d6
Merge pull request #3669 from pi-hole/release/v5.1.2
Release/v5.1.2 to development
2020-08-14 16:28:53 +01:00
Christian König
5c72ff75d9 Revert "fix #3336 by creating adlist file even if no list was selected by user"
This reverts commit 3c6ea2612d.

Signed-off-by: Christian König <ckoenig@posteo.de>
2020-08-10 23:52:53 +02:00
DL6ER
b5983a3fc1
Do not require first element to be a hex value at any costs. It may also be a : in the valid address ::1
Signed-off-by: DL6ER <dl6er@dl6er.de>
2020-08-04 22:11:32 +02:00
DL6ER
319b8eef75
Merge pull request #3527 from MichaIng/patch-1
Add default locations to PATH to assure that all basic commands are available
2020-07-31 18:14:45 +02:00
Adam Warner
48820d181c
Merge pull request #3620 from yubiuser/tweak/dig_supportedOS
Report and exit if dig supportedOS returns nothing
2020-07-30 17:00:01 +01:00
Christian Göttsche
51daeaa6ab basic-install: document how to continue after SELinux check
Signed-off-by: Christian Göttsche <cgzones@googlemail.com>
2020-07-30 14:50:42 +02:00
Christian König
6fc7dc28a2 Count elements of array instead
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-07-28 10:25:57 +02:00
Christian König
b207ceeab2 Report and exit if dig supportedOS returns nothing
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-07-28 09:51:31 +02:00
Christian König
8380112129 Resolve conflicts
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-07-28 09:40:45 +02:00
Adam Warner
0ff32c3629
Use ns1.pi-hole.net to resolve versions.pi-hole.net so that we do not see DNS cookie issues
Co-Authored-by: Dan Schaper <dan.schaper@pi-hole.net>
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-07-27 17:44:22 +01:00
Dan Schaper
0a81d687e8
Update automated install/basic-install.sh 2020-07-26 12:31:11 -07:00
Christian König
dfcdfd4b0a Remove empty line
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-07-26 12:27:55 +02:00
Christian König
ec9f490fcc Remove separate install function, move to installConfigs(), use pihole syntax
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-07-24 20:32:32 +02:00
Christian König
331502e14c Add variable that got lost
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-07-23 20:52:21 +02:00
Christian König
18c24d985f Create custom.list during install/update if it doesn't exist
Signed-off-by: Christian König <ckoenig@posteo.de>
2020-07-23 20:43:12 +02:00
Adam Warner
ddb36c013d
it helps if the echo goes variable set goes in the right place
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-07-22 22:39:03 +01:00
Adam Warner
98dc51869e
accidentally missed \\n
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-07-22 22:30:51 +01:00
Adam Warner
510b646736
change up the verbiage with something that works (tested)
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-07-22 22:29:38 +01:00
Adam Warner
ea22774d16
Wrap entire function in the check for the ENVVAR
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-07-21 18:47:13 +01:00
MichaIng
25b873cf7b Add default locations to PATH to assure that all basic commands are available
Signed-off-by: MichaIng <micha@dietpi.com>
2020-07-18 17:30:27 +02:00
Adam Warner
643d2c0f3e
add missing port number validation section to valid_ip6
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-07-16 21:31:45 +01:00
Adam Warner
533e5dddd0
clarify examples in case of unsupported OS
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-07-16 18:33:53 +01:00
Adam Warner
acfb092e4b
fix minor bug in 5.1
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-07-15 23:38:08 +01:00
Adam Warner
3205606fc3
Also validate IPV6 in the setdns function
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-06-23 20:38:18 +01:00
DL6ER
2c3aa9ab00
Merge pull request #3491 from pi-hole/fix_ip_address_section
Fix fresh install on dev branch not working
2020-06-21 21:58:36 +02:00
DL6ER
bf392d7a60
Merge pull request #3489 from pi-hole/ip_validation
Improve IP validation function
2020-06-21 21:56:30 +02:00
Adam Warner
bbfbf67fcf
further simplify the function, per @dl6er's suggestion
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-06-15 22:52:24 +01:00
Adam Warner
fe30ce10d3
simpler regex suggested by @MichaIng
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-06-15 21:21:40 +01:00
Adam Warner
7ea6d7b92b
remove ; so IFS changes don't stick
Co-authored-by: Dan Schaper <dan.schaper@pi-hole.net>
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-06-14 00:17:51 +01:00
Adam Warner
1ebf0785b6
move dnsutils/bind-utils to installed deps and only check OS is supported after installing installer deps
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-06-13 21:33:03 +01:00
Adam Warner
95f4c632f7
expand valid_ip to allow for custom ports
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
2020-06-13 20:30:03 +01:00
Dan Schaper
4b59287683
Merge pull request #3441 from pi-hole/new/os_check
Display warning if unsupported OS is detected
2020-06-05 13:39:39 -07:00