Changeset 2006 in ProjectBuilder
- Timestamp:
- Oct 2, 2015, 4:35:19 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
devel/pb-doc/pb-demo
r1983 r2006 57 57 # Mount the external HDD if needed 58 58 sudo mount /dev/sdc1 /mnt 59 sudo mount -o bind /mnt/docker /var/cache/docker59 $ sudo mount -o bind /run/media/bruno/pb+docker/docker /var/cache/docker 60 60 # Then restart docker to avoid errors with Attempt to write a readonly database 61 sudo systemctl restart docker62 sudo systemctl restart docker_registry61 $ sudo systemctl restart docker 62 $ sudo systemctl restart docker_registry 63 63 # Now show how easy it's to build for another distro in a Docker VE 64 64 # Create Docker container 65 docker images 65 $ docker images 66 67 # If docker issue with net, restart docker 68 $ sudo ip link delete docker0 69 $ sudo systemctl restart docker.service 66 70 67 71 # Building with rpmbootstrap for a distro 68 # That one has already been done to save time during demo 69 #pb -p pb -m mageia-4-x86_64 -T docker newve 70 # But we can launch in // the same for mga5 71 #pb -p pb -m mageia-5-x86_64 -T docker newve 72 docker images 73 docker run -ti <imgid> /bin/bash 74 $ urpmi tar 75 pb -p pb -m mageia-4-x86_64 -T docker sbx2setupve 76 docker ps -a 77 docker attach <ctnid> 78 docker images 79 docker run -ti <imgid> /bin/bash 80 pb -h 81 pb -p pb -m mageia-4-x86_64 -T docker prepve 82 docker images 83 docker run -ti <imgid> /bin/bash 84 pb -p pb -m mageia-4-x86_64 -T docker sbx2ve 85 ls -al /var/ftp/pub/pb/test/mageia/4/x86_64 72 # We already imported the upstream container images to save time 73 # Start with the local distro to simplify 74 # 75 $ pb -p pb -m mageia-5-x86_64 -T docker -i mageia:5 newve 76 # or without -i if time permits using rpmbootstrap 77 $ docker images | grep mageia-5 78 $ docker images | grep mageia-5 | awk '{print $3}' 79 $ docker run -ti `docker images | grep mageia-5 | awk '{print $3}'` /bin/bash 80 [root@8158b86786a7 /]# cat /etc/mageia-release 81 Mageia release 5 (Official) for x86_64 82 [root@8158b86786a7 /]# uname -a 83 Linux 8158b86786a7 3.19.8-desktop-3.mga5 #1 SMP Sat Jun 13 17:05:48 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux 84 [root@8158b86786a7 /]# urpmi tcsh 85 http://distro.ibiblio.org/mageia/distrib/5/x86_64/media/core/release/tcsh-6.18.01-8.mga5.x86_64.rpm 86 installing tcsh-6.18.01-8.mga5.x86_64.rpm from /var/cache/urpmi/rpms 87 Preparing... ############################################# 88 1/1: tcsh ############################################# 89 [root@8158b86786a7 /]# pb --help 90 bash: pb: command not found 91 [root@8158b86786a7 /]# exit 92 pb -p pb -m mageia-5-x86_64 -T docker sbx2setupve 93 $ docker images | grep mageia-5 94 localhost:5000/pb mageia-5-x86_64-pb 43bcfd269f29 2 minutes ago 376.2 MB 95 localhost:5000/pb mageia-5-x86_64 466f10e78bba 16 minutes ago 184.5 MB 96 $ docker run -ti `docker images | grep mageia-5-x86_64-pb | awk '{print $3}'` /bin/bash 97 [root@bbd981bcf4cd /]# pb --help 98 pb (aka project-builder.org) Version devel20150930111943-2002 99 [root@bbd981bcf4cd /]# exit 100 $ pb -p pb -m mageia-5-x86_64 -T docker prepve 101 $ docker images | grep mageia-5-x86_64-pb-pb 102 localhost:5000/pb mageia-5-x86_64-pb-pb 66dd65cab2cc About a minute ago 378.9 MB 103 $ pb -p pb -m mageia-5-x86_64 -T docker sbx2ve 104 105 106 # On another distro already preped 107 # we can launch in // the same for ubuntu 15.04 108 $ pb -p pb -m ubuntu-15.04-x86_64 -T docker -i ubuntu:15.04 newve 109 $ pb -p pb -m ubuntu-15.04-x86_64 -T docker sbx2setupve 110 $ pb -p pb -m ubuntu-15.04-x86_64 -T docker prepve 111 $ pb -p pb -m ubuntu-15.04-x86_64 -T docker sbx2ve 112 113 114 # Another container Ubuntu 13.10 115 $ pb -p pb -m ubuntu-13.10-x86_64 -T docker build2ve 116 $ ls -al /var/ftp/pub/pb/test/ubuntu/13.10 117 118 # On another project 119 $ pb -p mondorescue -m mageia-4-x86_64 -T docker prepve 120 $ docker images 121 $ ls -al /var/ftp/pub/pb/test/mageia/4/x86_64 122 $ ssh bruno@www.mondorescue.org ls -altrg /prj/ftp/test/mageia/4/x86_64 123 124 125 # Look at what was created 126 $ docker images 127 $ docker history localhost:5000/pb:mageia-4-x86_64-pb-pb 128 129 $ docker ps -a 130 $ docker attach <ctnid> 131 $ docker images 132 $ docker run -ti <imgid> /bin/bash 133 $ pb -h 134 $ docker run -ti <imgid> /bin/bash 135 $ ls -al /var/ftp/pub/pb/test/mageia/4/x86_64 86 136 # 87 # On another distro already preped88 # Another container Ubuntu 13.1089 pb -p pb -m ubuntu-13.10-x86_64 -T docker build2ve90 ls -al /var/ftp/pub/pb/test/ubuntu/13.1091 92 # On another project93 pb -p mondorescue -m mageia-4-x86_64 -T docker prepve94 docker images95 ls -al /var/ftp/pub/pb/test/mageia/4/x86_6496 ssh bruno@www.mondorescue.org ls -altrg /prj/ftp/test/mageia/4/x86_6497 98 99 # Look at what was created100 docker images101 docker history localhost:5000/pb:mageia-4-x86_64-pb-pb102 103 # From an upstream image instead of using ours.104 pb -p pb -m mageia-5-x86_64 -T docker -i mageia:5 newve105 106 # If docker issue with net, restart docker107 ip link delete docker0108 systemctl restart docker.service109 137 110 138 # WIth VMs
Note:
See TracChangeset
for help on using the changeset viewer.