On installations such as OctoPi, git is shadowed by /root/bin/git. This change forces the script to use /usr/bin/git which isn't affected by other executables with the name 'git' in the path.
Add support for Ubuntu Jammy (22.04)
Add CI tests for Ubuntu Jammy
Remove CI tests for Ubuntu Xenial
Rename CI tests stages
Add new CI Scripts to get pipeline code more "DRY"
Update CI Scripts to exit on error with /bin/bash -e
Add semantic-release settings
Add CI Release step for PiVPN automated versioning
in which case there is no dedicated file in /lib/modules. A rare case but possible.
Additionally the recursive globbing has been replaced by dpkg-query's internal recursive asterisk matching, which performs better/faster. This does now also match on "wireguard.kosomething", but I think "wireguard" is specific enough and dots in kernel modules names uncommon, to no be an issue.
Signed-off-by: MichaIng <micha@dietpi.com>
debconf-apt-progress is a tool to show a whiptail based dialog with progress bar for apt package installs, but it is some downsides:
- It aborts whenever apt or debconf halt for an interactive input, hence this would need to be prevented carefully, e.g. via "DEBIAN_FRONTEND=noninteractive" and "--force-confdef/old/new/miss", while it is questionable whether PiVPN should mute such configuration inputs for users.
- It even aborts when such interactive input is not actually required in some cases, but triggered by some other debconf load internals: pivpn#1360
Most importantly, aside of the visually probably appealing progress bar, debconf-apt-progress has not any upsides but reduces transparency of what is actually done, and the installer has a fallback already.
This commit removes the debconf-apt-progress usage in favour of the fallback: direct apt-get usage.
Signed-off-by: MichaIng <micha@dietpi.com>
There is only a single wget call in the installer, at the beginning of a pipe where curl may be the more natural choice. Since curl is a dependency already, this commit replaces the only wget call with curl and hence removes wget from installer dependencies.
Additionally, all curl calls get additional flags:
-s: The "silent" flag is now consequently used to suppress all processing output. It is not necessarily required when the STDOUT is a pipe or command substitution, but it does not hurt.
-S: Even when the curl output is piped, it may be helpful to have errors visible via STDERR, for debugging and being transparent about actual connection/download errors. This flag preserves error messages but does not send them to STDOUT, hence the data processed in the pipe or command substitution is not affected.
-f: There are cases where webservers return a 40x HTML document which is then printed to STDOUT by curl, like a 20x document, and hence unintentionally processed by the end of the pipe or command substitution. Usually this just cases a syntax error, but in theory it can have any unintended or even dangerous effect. The "fail" flag assures that 40x responses are printed as shortened error messages to STDERR and nothing is output to STDOUT. It should be hence seen as mandatory flag whenever curl is called to not print something to console but the output is processed.
-L: wget follows redirects automatically, curl requires the "-L" flag for this. For the wget => curl migration it is hence added to not change the behaviour.
Signed-off-by: MichaIng <micha@dietpi.com>