欢迎光临散文网 会员登陆 & 注册

云平台部署管理架构图

2023-02-18 13:13 作者:bili_39183997178  | 我要投稿

公有云配置

区域: 同一个区域中的云主机是可以互相连通的,不通区域云主机是不能使用内部网络互相通信的

选择离自己比较近的区域,可以减少网络延时卡顿

华为云yum源配置 https://support.huaweicloud.com/ecs_faq/ecs_faq_1003.html

跳板机配置

配置yum源,安装软件包

[root@ecs-proxy ~]# rm -rf /etc/yum.repos.d/*.repo

[root@ecs-proxy ~]# curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.myhuaweicloud.com/repo/CentOS-Base-7.repo

[root@ecs-proxy ~]# yum clean all

[root@ecs-proxy ~]# yum makecache

[root@ecs-proxy ~]# yum install -y net-tools lftp rsync psmisc vim-enhanced tree vsftpd  bash-completion createrepo lrzsz iproute

[root@ecs-proxy ~]# mkdir /var/ftp/localrepo

[root@ecs-proxy ~]# cd /var/ftp/localrepo

[root@ecs-proxy ~]# createrepo  .

[root@ecs-proxy ~]# createrepo --update . # 更新

[root@ecs-proxy ~]# systemctl enable --now vsftpd

优化系统服务

[root@ecs-proxy ~]# systemctl stop postfix atd tuned

[root@ecs-proxy ~]# yum remove -y postfix at audit tuned kexec-tools firewalld-*

[root@ecs-proxy ~]# vim /etc/cloud/cloud.cfg

# manage_etc_hosts: localhost 注释掉这一行

[root@ecs-proxy ~]# reboot

安装配置ansible管理主机

[root@ecs-proxy ~]# tar zxf ansible_centos7.tar.gz

[root@ecs-proxy ~]# yum install -y ansible_centos7/*.rpm

[root@ecs-proxy ~]# ssh-keygen -t rsa -b 2048 -N '' -f /root/.ssh/id_rsa

[root@ecs-proxy ~]# chmod 0400 /root/.ssh/id_rsa

[root@ecs-proxy ~]# ssh-copy-id -i /root/.ssh/id_rsa.pub 模板主机IP

模板镜像配置

配置yum源,安装软件包

[root@ecs-host ~]# rm -rf /etc/yum.repos.d/*.repo

[root@ecs-host ~]# curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.myhuaweicloud.com/repo/CentOS-Base-7.repo

[root@ecs-host ~]# vim /etc/yum.repos.d/local.repo 

[local_repo]

name=CentOS-$releasever – Localrepo

baseurl=ftp://192.168.1.252/localrepo

enabled=1

gpgcheck=0

[root@ecs-host ~]# yum clean all

[root@ecs-host ~]# yum makecache

[root@ecs-host ~]# yum repolist

[root@ecs-host ~]# yum install -y net-tools lftp rsync psmisc vim-enhanced tree lrzsz bash-completion iproute

优化系统服务

[root@ecs-host ~]# systemctl stop postfix atd tuned

[root@ecs-host ~]# yum remove -y postfix at audit tuned kexec-tools firewalld-*

[root@ecs-host ~]# vim /etc/cloud/cloud.cfg

# manage_etc_hosts: localhost 注释掉这一行

[root@ecs-host ~]# yum clean all 

[root@ecs-host ~]# poweroff


云平台部署管理架构图的评论 (共 条)

分享到微博请遵守国家法律