安装准备
基本配置
本实验在VMware中搭建,centos7下搭建Docker
Docker 是一个开源的应用容器引擎,让开发者可以打包他们的应用以及依赖包到一个可移植的容器中,然后发布到任何流行的Linux或Windows操作系统的机器上,也可以实现虚拟化,容器是完全使用沙箱机制,相互之间不会有任何接口。
我们通过FileZilla软件将xiandian-paas.IOS 和centos7.iOS上传到虚拟机中
[root@localhost ~]# ll 查看iso镜像
total 13342028
-rw-------. 1 root root 1260 May 8 11:56 anaconda-ks.cfg
-rw-r--r--. 1 root root 4712300544 May 8 12:26 CentOS-7-x86_64-DVD-2009.iso
-rw-r--r--. 1 root root 8949929984 May 8 12:27 XianDian-PaaS-v2.1.iso
[root@localhost ~]#
ip 配置
BOOTPROTO=static
DEFROUTE=yes
NAME=ens33
ONBOOT=yes
IPADDR=192.168.100.25
NETMASK=255.255.255.0
GATEWAY=192.168.100.2
DNS=114.114.114.114
挂载镜像
[root@localhost ~]# mount -o loop XianDian-PaaS-v2.1.iso /mnt
mount: /dev/loop0 is write-protected, mounting read-only
[root@localhost ~]# mkdir -p /opt/centos
[root@localhost ~]# cd /mnt
[root@localhost mnt]# ll
total 6289
dr-xr-xr-x. 3 root root 10240 Apr 20 2017 docker
dr-xr-xr-x. 2 root root 4096 Apr 21 2017 docker_images
-r-xr-xr-x. 1 root root 5836 Apr 20 2017 install.sh
-rw-r--r--. 1 root root 6418531 Apr 21 2017 jenkins.zip
[root@localhost mnt]# cp -rfv * /opt/centos
‘docker’ -> ‘/opt/centos/docker’
‘jenkins.zip’ -> ‘/opt/centos/jenkins.zip’
[root@localhost mnt]# ll /opt/centos
total 6288
dr-xr-xr-x. 3 root root 4096 May 8 12:40 docker
dr-xr-xr-x. 2 root root 4096 May 8 12:40 docker_images
-r-xr-xr-x. 1 root root 5836 May 8 12:40 install.sh
-rw-r--r--. 1 root root 6418531 May 8 12:40 jenkins.zip
[root@localhost mnt]# mkdir -p /opt/system
[root@localhost ~]# mount -o loop CentOS-7-x86_64-DVD-2009.iso /opt/system
mount: /dev/loop1 is write-protected, mounting read-only
[root@localhost ~]# ll /opt/system
total 696
-rw-r--r--. 3 root root 14 Oct 29 2020 CentOS_BuildTag
drwxr-xr-x. 3 root root 2048 Oct 26 2020 EFI
-rw-rw-r--. 21 root root 227 Aug 30 2017 EULA
-rw-rw-r--. 21 root root 18009 Dec 9 2015 GPL
drwxr-xr-x. 3 root root 2048 Oct 26 2020 images
drwxr-xr-x. 2 root root 2048 Nov 2 2020 isolinux
drwxr-xr-x. 2 root root 2048 Oct 26 2020 LiveOS
drwxr-xr-x. 2 root root 673792 Nov 4 2020 Packages
drwxr-xr-x. 2 root root 4096 Nov 4 2020 repodata
-rw-rw-r--. 21 root root 1690 Dec 9 2015 RPM-GPG-KEY-CentOS-7
-rw-</