forked from community-scripts/ProxmoxVED
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnextdns-install.sh
More file actions
executable file
·46 lines (39 loc) · 1.18 KB
/
Copy pathnextdns-install.sh
File metadata and controls
executable file
·46 lines (39 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#!/usr/bin/env bash
# Copyright (c) 2021-2026 community-scripts ORG
# Author: Nick Berardi (nberardi)
# License: MIT | https://github.com/community-scripts/ProxmoxVED/raw/main/LICENSE
# Source: https://nextdns.io | https://github.com/nextdns/nextdns
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
color
verb_ip6
catch_errors
setting_up_container
network_check
update_os
setup_deb822_repo \
"nextdns" \
"https://repo.nextdns.io/nextdns.gpg" \
"https://repo.nextdns.io/deb" \
"stable" \
"main"
msg_info "Installing NextDNS"
$STD apt install -y nextdns
msg_ok "Installed NextDNS"
if [[ -z "${var_nextdns_profile:-}" ]]; then
echo -e "${INFO}${YW}Get your profile ID from: https://my.nextdns.io${CL}"
read -r -p "${TAB3}NextDNS Profile ID: " var_nextdns_profile
fi
var_nextdns_profile="${var_nextdns_profile//[[:space:]]/}"
if [[ -z "${var_nextdns_profile}" ]]; then
msg_error "NextDNS Profile ID is required (set var_nextdns_profile or enter it when prompted)"
exit 1
fi
msg_info "Configuring NextDNS"
nextdns install \
-profile "${var_nextdns_profile}" \
-report-client-info \
-setup-router
msg_ok "Configured NextDNS (profile ${var_nextdns_profile})"
motd_ssh
customize
cleanup_lxc