badguardhome/scripts/install.sh

244 lines
4.7 KiB
Bash
Raw Normal View History

Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
#!/bin/sh
Pull request: all: add a new Makefile and scripts, remove goreleaaser Merge in DNS/adguard-home from 2276-releases to master Updates #2276. Squashed commit of the following: commit 84961947c51477aae53606ec6e2e0cce0bdfc139 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Dec 30 14:36:13 2020 +0300 all: fix github build commit 54af2adbf2f433e80393fb142e66ba6b3a78b13e Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Dec 30 14:34:02 2020 +0300 all: remove old Dockerfile, improve build scripts commit 99bb2f2ba1458d32074ac0911b5c02ce6669e43e Merge: 2292b677a 5e20ac7ed Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Dec 30 13:47:19 2020 +0300 Merge branch 'master' into WIP-2276-releases commit 2292b677a20ce8e93d9e6e2bb042cd468606fec3 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Dec 30 13:30:10 2020 +0300 all: improve docker build commit 0bcc97c41f105ee4a4363f20fa4775c7643bf0cc Merge: c7d3f12ef aef4659e9 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 17:47:45 2020 +0300 Merge branch 'master' into WIP-2276-releases commit c7d3f12ef2b63ddfa2acf46e3129fcbc56fb0a90 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 16:28:25 2020 +0300 all: improve build scripts commit 55de1e5d7ef0fbdbd1a76cfb71362d16ca0a1966 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 15:36:47 2020 +0300 all: fix Makefile commit d11b1fe28d0fde1efeaf6160a614951b19d0ef94 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 14:16:19 2020 +0300 scripts: fix build-release commit ecc0577e2451afa86c37da7283a63a9d26fb37ba Merge: dde64ed8e 483f02c92 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 13:59:32 2020 +0300 Merge branch 'master' into WIP-2276-releases commit dde64ed8e456f73559f21c2ca549dc3b46724add Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Dec 25 18:04:46 2020 +0300 all: imp docs, other improvements commit be8574408db79901bb15c1d31916db3ca352a35f Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Dec 25 14:48:30 2020 +0300 all: imp docker build commit fc1876f34b93d667bf166226f4bc666d394f10c7 Merge: fa5a304c8 955b735c8 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Dec 25 13:54:29 2020 +0300 Merge branch 'master' into WIP-2276-releases commit fa5a304c83d86145796a2de4141de6d18f7c56bf Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 19:10:51 2020 +0300 all: improve scripts commit 3f32e3fd5e658d058d5c5172519384efc6cfef83 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 18:50:01 2020 +0300 all: improve scripts commit 2d38b81421acab4b90a7a19da7598c75063e8e93 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 18:25:21 2020 +0300 all: fix shell for windows, improve go-lint.sh commit d695285cd6dc476c0d972cfe0c49bbeea5f5a049 Merge: 313b020e9 9fb6bf82c Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 18:14:38 2020 +0300 Merge branch 'master' into WIP-2276-releases commit 313b020e9dfcdab736670cee72b2171eac8c32b7 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 18:13:31 2020 +0300 Makefile: use npm ci again commit 5acee9d6a6c8cd2a7dd04b173a73929650882bad Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 17:57:54 2020 +0300 all: try fixing windows build commit c63a2a54641ac8cd032a3306bb35e49b9ae74728 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 17:39:30 2020 +0300 all: imp scripts, try another goproxy and direct commit 423229e8b63ee73caeee8e84c23f67d145aff9df Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 17:25:29 2020 +0300 all: imp HACKING.md, try a new proxy ... and 1 more commit
2020-12-30 15:26:25 +00:00
# AdGuard Home Installation Script
Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
#
# 1. Download the package
# 2. Unpack it
# 3. Install as a service
#
# Requirements:
# . bash
# . which
# . printf
# . uname
# . id
# . head, tail
# . curl
# . tar or unzip
# . rm
set -e
log_info()
{
printf "[info] %s\\n" "$1"
}
log_error()
{
printf "[error] %s\\n" "$1"
}
# Get OS
# Return: darwin, linux, freebsd
detect_os()
{
UNAME_S="$(uname -s)"
OS=
case "$UNAME_S" in
Linux)
OS=linux
;;
FreeBSD)
OS=freebsd
;;
Darwin)
OS=darwin
;;
*)
return 1
;;
esac
echo $OS
}
# Get CPU endianness
# Return: le, ""
cpu_little_endian()
{
ENDIAN_FLAG="$(head -c 6 /bin/bash | tail -c 1)"
if [ "$ENDIAN_FLAG" = "$(printf '\001')" ]; then
echo 'le'
return 0
fi
}
# Get CPU
# Return: amd64, 386, armv5, armv6, armv7, arm64, mips_softfloat, mipsle_softfloat, mips64_softfloat, mips64le_softfloat
detect_cpu()
{
UNAME_M="$(uname -m)"
CPU=
case "$UNAME_M" in
x86_64 | x86-64 | x64 | amd64)
CPU=amd64
;;
i386 | i486 | i686 | i786 | x86)
CPU=386
;;
armv5l)
CPU=armv5
;;
armv6l)
CPU=armv6
;;
armv7l | armv8l)
CPU=armv7
;;
aarch64 | arm64)
Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
CPU=arm64
;;
mips)
LE=$(cpu_little_endian)
CPU=mips${LE}_softfloat
;;
mips64)
LE=$(cpu_little_endian)
CPU=mips64${LE}_softfloat
;;
*)
return 1
esac
echo "${CPU}"
}
# Get package file name extension
# Return: tar.gz, zip
package_extension()
{
if [ "$OS" = "darwin" ]; then
echo "zip"
return 0
fi
echo "tar.gz"
}
# Download data to a file
# Use: download URL OUTPUT
download()
{
log_info "Downloading package from $1 -> $2"
if is_command curl ; then
curl -s "$1" --output "$2" || error_exit "Failed to download $1"
else
error_exit "curl is necessary to install AdGuard Home"
fi
}
# Unpack package to a directory
# Use: unpack INPUT OUTPUT_DIR PKG_EXT
unpack()
{
log_info "Unpacking package from $1 -> $2"
mkdir -p "$2"
if [ "$3" = "zip" ]; then
unzip -qq "$1" -d "$2" || return 1
elif [ "$3" = "tar.gz" ]; then
tar xzf "$1" -C "$2" || return 1
else
return 1
fi
}
# Print error message and exit
# Use: error_exit MESSAGE
error_exit()
{
log_error "$1"
exit 1
}
# Check if command exists
# Use: is_command COMMAND
is_command() {
check_command="$1"
command -v "${check_command}" >/dev/null 2>&1
}
# Entry point
main() {
log_info "Starting AdGuard Home installation script"
CHANNEL=${1}
if [ "${CHANNEL}" != "beta" ] && [ "${CHANNEL}" != "edge" ]; then
CHANNEL=release
fi
log_info "Channel ${CHANNEL}"
OS=$(detect_os) || error_exit "Cannot detect your OS"
CPU=$(detect_cpu) || error_exit "Cannot detect your CPU"
2021-01-31 21:49:04 +00:00
# TODO: Remove when Mac M1 native support is added
if [ "${OS}" = "darwin" ] && [ "${CPU}" = "arm64" ]; then
CPU="amd64"
log_info "Use ${CPU} build on Mac M1 until the native ARM support is added"
fi
Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
PKG_EXT=$(package_extension)
PKG_NAME=AdGuardHome_${OS}_${CPU}.${PKG_EXT}
SCRIPT_URL="https://raw.githubusercontent.com/AdguardTeam/AdGuardHome/master/scripts/install.sh"
URL="https://static.adguard.com/adguardhome/${CHANNEL}/${PKG_NAME}"
2021-01-31 21:14:47 +00:00
OUT_DIR="/opt"
if [ "${OS}" = "darwin" ]; then
# It may be important to install AdGuard Home to /Applications on MacOS
# Otherwise, it may not grant enough privileges to it
OUT_DIR="/Applications"
fi
AGH_DIR="${OUT_DIR}/AdGuardHome"
Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
# Root check
if [ "$(id -u)" -eq 0 ]; then
log_info "Script called with root privileges"
else
if is_command sudo ; then
log_info "Please note, that AdGuard Home requires root privileges to install using this script."
log_info "Restarting with root privileges"
exec curl -sSL ${SCRIPT_URL} | sudo sh -s "$@"
exit $?
else
log_info "Root privileges are required to install AdGuard Home using this installer."
log_info "Please, re-run this script as root."
exit 1
fi
fi
log_info "AdGuard Home will be installed to ${AGH_DIR}"
Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
[ -d "${AGH_DIR}" ] && [ -n "$(ls -1 -A -q ${AGH_DIR})" ] && error_exit "Directory ${AGH_DIR} is not empty, abort installation"
Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
download "${URL}" "${PKG_NAME}" || error_exit "Cannot download the package"
unpack "${PKG_NAME}" "${OUT_DIR}" "${PKG_EXT}" || error_exit "Cannot unpack the package"
# Install AdGuard Home service and run it.
( cd "${AGH_DIR}" && ./AdGuardHome -s install || error_exit "Cannot install AdGuardHome as a service" )
Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
rm "${PKG_NAME}"
log_info "AdGuard Home is now installed and running."
log_info "You can control the service status with the following commands:"
log_info " sudo ${AGH_DIR}/AdGuardHome -s start|stop|restart|status|install|uninstall"
Merge: + install.sh Merge in DNS/adguard-home from install.sh to master Fix #995 Squashed commit of the following: commit 81a5b6385574fa5bc14f7e9cc8cd707fcdc491c3 Merge: 825062a9 fb7ca942 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:40:30 2020 +0300 Merge branch 'master' into install.sh commit 825062a9cb77447bec0967635bde334218437e1f Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:04:04 2020 +0300 minor fixes commit 22205d80479a1f894fe6c72afe22ba555a9e611e Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 20:01:56 2020 +0300 * (home): fix install script commit 073b5fb8e27351094b95d85335dd3d08f65f9ee8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 19:59:07 2020 +0300 * (home): update readme and install script commit d4d2e4c35ca1ea1f365e40081098ee9398196ef3 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 14:43:49 2020 +0300 disable parallel build commit a639b9ae44c534c7fdecd34894f5ad4ae6217472 Author: Andrey Meshkov <am@adguard.com> Date: Wed Oct 7 02:48:52 2020 +0300 * (home): improve install.sh commit 4c564da714850002d1810d4d10dce859f340e3ab Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:32:53 2020 +0300 minor commit 0ecc1a03a41201a632f650ba995f3b07a6539889 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Oct 1 15:08:07 2020 +0300 * install.sh: use /opt/AdGuardHome output directory commit fd3ad73606c69e8ede086e67bc557772f9e34406 Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Sep 30 12:13:56 2020 +0300 * install.sh: prompt for an output directory commit 8917e8cb3d794cfa1fd7b358c89695ff719e7e4d Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Sep 29 18:56:54 2020 +0300 + install.sh
2020-10-07 18:01:30 +00:00
}
Pull request: all: add a new Makefile and scripts, remove goreleaaser Merge in DNS/adguard-home from 2276-releases to master Updates #2276. Squashed commit of the following: commit 84961947c51477aae53606ec6e2e0cce0bdfc139 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Dec 30 14:36:13 2020 +0300 all: fix github build commit 54af2adbf2f433e80393fb142e66ba6b3a78b13e Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Dec 30 14:34:02 2020 +0300 all: remove old Dockerfile, improve build scripts commit 99bb2f2ba1458d32074ac0911b5c02ce6669e43e Merge: 2292b677a 5e20ac7ed Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Dec 30 13:47:19 2020 +0300 Merge branch 'master' into WIP-2276-releases commit 2292b677a20ce8e93d9e6e2bb042cd468606fec3 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Dec 30 13:30:10 2020 +0300 all: improve docker build commit 0bcc97c41f105ee4a4363f20fa4775c7643bf0cc Merge: c7d3f12ef aef4659e9 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 17:47:45 2020 +0300 Merge branch 'master' into WIP-2276-releases commit c7d3f12ef2b63ddfa2acf46e3129fcbc56fb0a90 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 16:28:25 2020 +0300 all: improve build scripts commit 55de1e5d7ef0fbdbd1a76cfb71362d16ca0a1966 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 15:36:47 2020 +0300 all: fix Makefile commit d11b1fe28d0fde1efeaf6160a614951b19d0ef94 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 14:16:19 2020 +0300 scripts: fix build-release commit ecc0577e2451afa86c37da7283a63a9d26fb37ba Merge: dde64ed8e 483f02c92 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Dec 29 13:59:32 2020 +0300 Merge branch 'master' into WIP-2276-releases commit dde64ed8e456f73559f21c2ca549dc3b46724add Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Dec 25 18:04:46 2020 +0300 all: imp docs, other improvements commit be8574408db79901bb15c1d31916db3ca352a35f Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Dec 25 14:48:30 2020 +0300 all: imp docker build commit fc1876f34b93d667bf166226f4bc666d394f10c7 Merge: fa5a304c8 955b735c8 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Dec 25 13:54:29 2020 +0300 Merge branch 'master' into WIP-2276-releases commit fa5a304c83d86145796a2de4141de6d18f7c56bf Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 19:10:51 2020 +0300 all: improve scripts commit 3f32e3fd5e658d058d5c5172519384efc6cfef83 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 18:50:01 2020 +0300 all: improve scripts commit 2d38b81421acab4b90a7a19da7598c75063e8e93 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 18:25:21 2020 +0300 all: fix shell for windows, improve go-lint.sh commit d695285cd6dc476c0d972cfe0c49bbeea5f5a049 Merge: 313b020e9 9fb6bf82c Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 18:14:38 2020 +0300 Merge branch 'master' into WIP-2276-releases commit 313b020e9dfcdab736670cee72b2171eac8c32b7 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 18:13:31 2020 +0300 Makefile: use npm ci again commit 5acee9d6a6c8cd2a7dd04b173a73929650882bad Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 17:57:54 2020 +0300 all: try fixing windows build commit c63a2a54641ac8cd032a3306bb35e49b9ae74728 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 17:39:30 2020 +0300 all: imp scripts, try another goproxy and direct commit 423229e8b63ee73caeee8e84c23f67d145aff9df Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Dec 24 17:25:29 2020 +0300 all: imp HACKING.md, try a new proxy ... and 1 more commit
2020-12-30 15:26:25 +00:00
main "$@"