[1838] | 1 | pafio.spelder
|
---|
| 2 | cemo of project-builder.org
|
---|
[814] | 3 | ===========================
|
---|
| 4 |
|
---|
| 5 | # First demonstrate the way of working for pb itself
|
---|
[1835] | 6 | cd ~/local/pb|~/pb|~/svn-git/pb
|
---|
[814] | 7 | # Show the various versions available in this SVK exported dir
|
---|
| 8 | ls
|
---|
| 9 | # get the current tag of the SVK repository
|
---|
[1835] | 10 | svk info|svn info|git svn info
|
---|
[814] | 11 |
|
---|
| 12 | # get the current version of project-builder
|
---|
| 13 | rpm -q project-builder
|
---|
[817] | 14 | pb --help
|
---|
[1835] | 15 | pb
|
---|
[814] | 16 |
|
---|
| 17 | # Decide to build a package for project-builder based on that devel version
|
---|
| 18 | # to replace the one currently installed
|
---|
[1835] | 19 | pb -p pb -r devel sbx2build|cms2build
|
---|
[814] | 20 |
|
---|
| 21 | # Show the upstream part
|
---|
[1835] | 22 | ls -altg /home/bruno/svn-git/pb/delivery/
|
---|
| 23 | tar tvfz /home/bruno/svn-git/pb/delivery/project-builder-develXXX.tar.gz
|
---|
[814] | 24 |
|
---|
| 25 | # Show the pb specific part
|
---|
[1835] | 26 | tar tvfz /home/bruno/svn-git/pb/delivery/project-builder-develXXX.pbconf.tar.gz
|
---|
[814] | 27 |
|
---|
| 28 | # Now make the packages
|
---|
| 29 | pb -p pb build2pkg
|
---|
| 30 |
|
---|
| 31 | # Look at the latest pckges created
|
---|
[1835] | 32 | ls -altrg /home/bruno/svn-git/pb/build/RPMS/noarch
|
---|
[814] | 33 |
|
---|
| 34 | # Install the generated packages
|
---|
[1835] | 35 | sudo urpmi /home/bruno/svn-git/pb/build/RPMS/noarch/*.rpm
|
---|
[814] | 36 |
|
---|
| 37 | # Check that it's the right one
|
---|
[816] | 38 | rpm -q project-builder
|
---|
[1407] | 39 | pb --version
|
---|
[1835] | 40 | git svn info
|
---|
[814] | 41 |
|
---|
[817] | 42 | # Now show how easy it's to build for another distro in a VM
|
---|
[1101] | 43 | ls /home/qemu
|
---|
[1835] | 44 | -> pb -p pb -m debian-7.1-x86_64 sbx2vm
|
---|
| 45 | ls -al /var/ftp/pub/pb/test/debian/7.1/
|
---|
| 46 | ls -al /var/ftp/pub/pb/test/debian/dists/7.1/
|
---|
| 47 |
|
---|
| 48 | pb -p pb -m mageia-3-i386 sbx2vm
|
---|
[817] | 49 | # Now show how easy it's to build for another distro in a VE
|
---|
[1288] | 50 | ls /home/rpmbootstrap
|
---|
[1835] | 51 | pb -p pb -m centos-6-x86_64 build2ve
|
---|
| 52 | pb -p pb -m ubuntu-11.10-x86_64 build2ve
|
---|
| 53 | -> pb -p pb -m debian-6.0-x86_64 sbx2ve
|
---|
| 54 | ls -al /var/ftp/pub/pb/test/debian/6.0/
|
---|
| 55 | ls -al /var/ftp/pub/pb/test/debian/dists/6.0/
|
---|
[816] | 56 |
|
---|
[817] | 57 | # Now show how easy it's to build for another project for which I'm upstream
|
---|
[1835] | 58 | -> pb -p mondorescue -m debian-6.0-x86_64 sbx2ve
|
---|
[1288] | 59 |
|
---|
[817] | 60 | # Now show how easy it's to build for another project for which I'm not upstream with patches
|
---|
[1835] | 61 | -> pb -p afio -r 2.5 -m debian-6.0-x86_64 sbx2ve
|
---|
[816] | 62 |
|
---|
[1101] | 63 | # Look at conf files
|
---|
| 64 | cat ~/.pbrc
|
---|
[1288] | 65 | cat /home/rpmbootstrap/.pbrc
|
---|
[1835] | 66 | cat ~/svn-git/pb/projects/afio/pbconf/2.5/afio.pb
|
---|
[1838] | 67 | cat ~/svn-git/pb/projects/afio/pbconf/2.5/afio/rpm/afio.spec
|
---|
| 68 | cat ~/svn-git/pb/projects/afio/pbconf/2.5/afio/deb/control
|
---|
[1835] | 69 | ls -R ~/svn-git/pb/projects/afio/pbconf/2.5/
|
---|
[1288] | 70 |
|
---|
| 71 | # Short Lab
|
---|
| 72 | # in pblab account
|
---|
| 73 | # prepa
|
---|
| 74 | # As root
|
---|
| 75 | rm -rf /prj/svn
|
---|
| 76 | svnadmin create /prj/svn
|
---|
| 77 | cat >> /prj/svn/conf/authz << EOF
|
---|
| 78 | [/]
|
---|
| 79 | pblab = rw
|
---|
| 80 | * = r
|
---|
| 81 | EOF
|
---|
| 82 | cat >> /prj/svn/conf/passwd << EOF
|
---|
| 83 | pblab = pblab
|
---|
| 84 | EOF
|
---|
| 85 | cat > /prj/svn/conf/svnserve.conf << EOF
|
---|
| 86 | [general]
|
---|
| 87 | password-db = passwd
|
---|
| 88 | authz-db = authz
|
---|
| 89 | [sasl]
|
---|
| 90 | EOF
|
---|
| 91 | killall svnserve
|
---|
| 92 | ~pblab/bin/rc.local
|
---|
| 93 |
|
---|
| 94 | # as pblab
|
---|
| 95 | rm -rf pb .pbrc
|
---|
| 96 | cat > afio.pb.add << EOF
|
---|
| 97 | defpkgdir afio = dummy
|
---|
| 98 | pbpackager default = Big Chief <bigchief@hp.com>
|
---|
| 99 | projver afio = 2.5
|
---|
| 100 | projtag afio = 1
|
---|
| 101 | pburl afio = ftp://localhost/src/afio-2.5.tar.gz
|
---|
| 102 | pbrepo afio = ftp://localhost
|
---|
| 103 | EOF
|
---|
| 104 |
|
---|
| 105 | pb -p afio clean
|
---|
| 106 | cat ~/.pbrc
|
---|
| 107 | cat >> ~/.pbrc << EOF
|
---|
| 108 | pbconfurl afio = svn://localhost/pb/afio/pbconf
|
---|
| 109 | EOF
|
---|
| 110 | echo "pbdefdir default = \$ENV{'HOME'}/pb" >> ~/.pbrc
|
---|
| 111 | mkdir pb
|
---|
| 112 | svn import pb svn://localhost/pb -m "Initial creation of pb repo"
|
---|
| 113 | # passwd asked here
|
---|
| 114 |
|
---|
| 115 | cd pb
|
---|
| 116 | svn co svn://localhost/pb .
|
---|
| 117 | pb -p afio newproj afio
|
---|
| 118 | # passwd asked here
|
---|
| 119 |
|
---|
| 120 | cat ~/afio.pb.add >> afio/pbconf/afio.pb
|
---|
| 121 | pb -p afio sbx2build
|
---|
| 122 |
|
---|
| 123 | # with Ubuntu CD
|
---|
| 124 | cat >> ~/.pbrc << EOF
|
---|
| 125 | vmpath default = /home/qemu
|
---|
| 126 | EOF
|
---|
| 127 |
|
---|