mirror of
https://github.com/bin456789/reinstall.git
synced 2025-01-31 19:08:07 +08:00
core: 为 centos 7 云镜像安装 NetworkManager
This commit is contained in:
parent
ed9766de37
commit
c0e4423434
8
trans.sh
8
trans.sh
@ -1216,6 +1216,14 @@ install_qcow_el() {
|
|||||||
# cloud-init
|
# cloud-init
|
||||||
download_cloud_init_config /os
|
download_cloud_init_config /os
|
||||||
|
|
||||||
|
# 为 centos 7 ci 安装 NetworkManager
|
||||||
|
# 1. 能够自动配置 onlink 网关
|
||||||
|
# 2. 解决 cloud-init 关闭了 ra,因为 nm 无视内核 ra 设置
|
||||||
|
if grep 'centos:7' /os/etc/system-release-cpe; then
|
||||||
|
yum install -y NetworkManager
|
||||||
|
chroot /os/ systemctl enable NetworkManager
|
||||||
|
fi
|
||||||
|
|
||||||
# fstab 删除 boot 分区
|
# fstab 删除 boot 分区
|
||||||
# alma/rocky 镜像本身有boot分区,但我们不需要
|
# alma/rocky 镜像本身有boot分区,但我们不需要
|
||||||
sed -i '/[[:blank:]]\/boot[[:blank:]]/d' /os/etc/fstab
|
sed -i '/[[:blank:]]\/boot[[:blank:]]/d' /os/etc/fstab
|
||||||
|
Loading…
x
Reference in New Issue
Block a user