2023.08.04

This commit is contained in:
spiritlhl 2023-08-04 14:28:59 +00:00
parent e527358e34
commit c9f7fbf6e1
2 changed files with 3 additions and 3 deletions

View file

@ -18,6 +18,7 @@
- 开设独立IPV4地址的虚拟机时尝试增加自动附加IPV6地址的功能
- 增加一键开设纯IPV6虚拟机、纯IPV6容器的脚本
- 修复可能的dns-nameservers存在多行导致网络异常的问题
- 特殊处理没有ifupdown的宿主机
[更新日志](CHANGELOG.md)

View file

@ -888,8 +888,7 @@ if [ ! -f "/usr/local/bin/reboot_pve.txt" ]; then
# prebuild_ifupdown2
# fi
fi
if [[ $dmidecode_output == *"Hetzner_vServer"* ]] || [ $dmidecode_output == *"Exoscale Compute Platform"* ]; then
# 特殊处理Hetzner
if [[ $dmidecode_output == *"Hetzner_vServer"* ]] || [[ $dmidecode_output == *"Exoscale Compute Platform"* ]] || ! command -v ifupdown; then
prebuild_ifupdown2
fi
# # 特殊处理OVH
@ -1118,7 +1117,7 @@ rebuild_interfaces
fix_interfaces_ipv6_auto_type
# 特殊处理Hetzner和Azure的情况
if [[ $dmidecode_output == *"Hetzner_vServer"* ]] || [[ $dmidecode_output == *"Microsoft Corporation"* ]] || [ $dmidecode_output == *"Exoscale Compute Platform"* ]; then
if [[ $dmidecode_output == *"Hetzner_vServer"* ]] || [[ $dmidecode_output == *"Microsoft Corporation"* ]] || [[ $dmidecode_output == *"Exoscale Compute Platform"* ]]; then
auto_interface=$(grep '^auto ' /etc/network/interfaces | grep -v '^auto lo' | awk '{print $2}' | head -n 1)
if ! grep -q "^post-up ${ethtool_path}" /etc/network/interfaces; then
chattr -i /etc/network/interfaces