##1.配置本地yum源## ##2.下载httpd 和 system-config-kickstart## yum install httpd system-config-kickstart -y ##3.system-config-kickstart打开,选择配置内容## ##5.编辑ks.cfg## [[email protected] html]# vim ks.cfg 改时间 %packages @base lftp %end %post cat >>/etc/yum.repos.d/yum.repo << [rhel7] name=rhel7 baseurl=http://172.25.254.16/rhel7/ gpgcheck=0 EOF %end ##6.开启服务,关火墙## [[email protected] html]# ksvalidator ks.cfg [[email protected] html]# systemctl start httpd [[email protected] html]# systemctl stop firewalld [[email protected] html]# systemctl disable firewalld [[email protected] html]# systemctl enable httpd ##7.编写自动安装脚本## vim /mnt/vm.sh chmod 755 vm.sh ##8.运行脚本## sh /mnt/vm.sh ##运行 相关文章: 2021-05-02 2021-05-30 2021-12-03 2021-10-05 2021-12-11