mirror of
https://github.com/thelittlerocket/pve.git
synced 2025-03-04 01:38:12 +08:00
Update install_pve.sh
This commit is contained in:
parent
8206b910aa
commit
61ff91f953
1 changed files with 8 additions and 10 deletions
|
@ -233,17 +233,15 @@ then
|
|||
echo "nameserver 8.8.8.8" | sudo tee /etc/resolv.conf > /dev/null
|
||||
chattr +i /etc/resolv.conf
|
||||
fi
|
||||
if [ $? -ne 0 ]; then
|
||||
if [[ -n "${CN}" ]]; then
|
||||
wget https://ghproxy.com/https://raw.githubusercontent.com/spiritLHLS/pve/main/check-dns.sh -O /usr/local/bin/check-dns.sh
|
||||
wget https://ghproxy.com/https://raw.githubusercontent.com/spiritLHLS/pve/main/check-dns.service -O /etc/systemd/system/check-dns.service
|
||||
else
|
||||
wget https://raw.githubusercontent.com/spiritLHLS/pve/main/check-dns.sh -O /usr/local/bin/check-dns.sh
|
||||
wget https://raw.githubusercontent.com/spiritLHLS/pve/main/check-dns.service -O /etc/systemd/system/check-dns.service
|
||||
fi
|
||||
chmod +x /usr/local/bin/check-dns.sh
|
||||
chmod +x /etc/systemd/system/check-dns.service
|
||||
if [[ -n "${CN}" ]]; then
|
||||
wget https://ghproxy.com/https://raw.githubusercontent.com/spiritLHLS/pve/main/check-dns.sh -O /usr/local/bin/check-dns.sh
|
||||
wget https://ghproxy.com/https://raw.githubusercontent.com/spiritLHLS/pve/main/check-dns.service -O /etc/systemd/system/check-dns.service
|
||||
else
|
||||
wget https://raw.githubusercontent.com/spiritLHLS/pve/main/check-dns.sh -O /usr/local/bin/check-dns.sh
|
||||
wget https://raw.githubusercontent.com/spiritLHLS/pve/main/check-dns.service -O /etc/systemd/system/check-dns.service
|
||||
fi
|
||||
chmod +x /usr/local/bin/check-dns.sh
|
||||
chmod +x /etc/systemd/system/check-dns.service
|
||||
systemctl daemon-reload
|
||||
systemctl enable check-dns.service
|
||||
systemctl start check-dns.service
|
||||
|
|
Loading…
Reference in a new issue