Changes

Jump to navigation Jump to search
Line 21: Line 21:  
The build_installer and build_ISO expect to be run from a directory that points to the head of the stage (ex. /build/stage/8). This is usually a symlink to 8.1 or 8.1beta1. The script fully expands the symlink and pulls off the last element to figure out what version we are going to build.  
 
The build_installer and build_ISO expect to be run from a directory that points to the head of the stage (ex. /build/stage/8). This is usually a symlink to 8.1 or 8.1beta1. The script fully expands the symlink and pulls off the last element to figure out what version we are going to build.  
 
  VER=10
 
  VER=10
  VERSION=$VER.0.rc1
+
  VERSION=$VER.1
  VERPREV=$VER.0.beta1
+
  VERPREV=$VER.0
    
  mkdir -p /build/smeserver/stage/$VERSION/{SRPMS,x86_64}
 
  mkdir -p /build/smeserver/stage/$VERSION/{SRPMS,x86_64}
  mkdir -p /build/smeserver/stage/$VERSION/x86_64/{Packages,EFI,images,isolinux,LiveOS,repodata,repoview,updates,product,netinstall}
+
  mkdir -p /build/smeserver/stage/$VERSION/x86_64/{Packages/base,EFI/BOOT,images/pxeboot,isolinux,LiveOS,repodata,repoview,updates,product,netinstall}
  mkdir -p /build/smeserver/stage/$VERSION/x86_64/Packages/base
+
  mkdir -p /build/smeserver/stage/$VERSION/x86_64/updates/{po,textw,iw,storage/devicelibs}
mkdir -p /build/smeserver/stage/$VERSION/x86_64/images/pxeboot
   
  cd /build/smeserver/stage/
 
  cd /build/smeserver/stage/
 
  rm -f $VER
 
  rm -f $VER
Line 37: Line 36:     
Get CentOS last images content
 
Get CentOS last images content
  cd /build/smeserver/stage/$VERSION/x86_64/Packages/images
+
  cd /build/smeserver/stage/$VERSION/x86_64/images
 
  wget <nowiki>http://mirror.centos.org/centos/7/os/x86_64/images/boot.iso</nowiki> <nowiki>http://mirror.centos.org/centos/7/os/x86_64/images/efiboot.img</nowiki>
 
  wget <nowiki>http://mirror.centos.org/centos/7/os/x86_64/images/boot.iso</nowiki> <nowiki>http://mirror.centos.org/centos/7/os/x86_64/images/efiboot.img</nowiki>
 
  cd /build/smeserver/stage/$VERSION/x86_64/images/pxeboot
 
  cd /build/smeserver/stage/$VERSION/x86_64/images/pxeboot
Line 43: Line 42:     
Prepare to build the product.img. There should be some pictures to copy from previous builds. Some modification from anaconda
 
Prepare to build the product.img. There should be some pictures to copy from previous builds. Some modification from anaconda
  −
cd  /build/smeserver/stage/$VERSION/x86_64/product/
   
  rsync -arv /build/smeserver/repo/testing/$VERPREV/smeos/x86_64/product /build/smeserver/stage/$VERSION/x86_64/
 
  rsync -arv /build/smeserver/repo/testing/$VERPREV/smeos/x86_64/product /build/smeserver/stage/$VERSION/x86_64/
  −
make any needed modification in the product image. at least update the release version
  −
vim .buildstamp
  −
  −
those files should be updated via anaconda, if not, do it and return there.
  −
cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.159/pyanaconda/installclasses/koozali.py  run/install/product/pyanaconda/installclasses/
  −
cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.159/pyanaconda/installclasses/koozali.py usr/lib64/python2.7/site-packages/pyanaconda/installclasses/
  −
cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.159/pyanaconda/installclasses/centos.py usr/lib64/python2.7/site-packages/pyanaconda/installclasses/
  −
cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.159/pyanaconda/installclasses/fedora.py usr/lib64/python2.7/site-packages/pyanaconda/installclasses/
  −
  −
build new product.img and copy it to stage, if you want but it should be done by the build.ISO script
  −
#find . | cpio -c -o | gzip -9cv > ../product.img; cd ..
  −
#mkdir -p /build/smeserver/stage/$VER/x86_64/images/
  −
#cp product.img /build/smeserver/stage/$VER/x86_64/images/
      
Populate isolinux dir:
 
Populate isolinux dir:
 
  rsync -arv /mirrors/centos/7/os/x86_64/isolinux/* /build/smeserver/stage/$VERSION/x86_64/isolinux/
 
  rsync -arv /mirrors/centos/7/os/x86_64/isolinux/* /build/smeserver/stage/$VERSION/x86_64/isolinux/
 
+
could also be from previous iso
now if you have not updated files for isolinux in smeserver/cdrom.image/sme10/isolinux in cvs it is time, and also to refresh the local copy
+
  rsync -arv /build/smeserver/stage/$VERPREV/x86_64/isolinux/* /build/smeserver/stage/$VERSION/x86_64/isolinux/
pushd ~/smeserver/cdrom.image/sme10/
  −
cvs update
  −
popd
  −
  rsync -arv ~/smeserver/cdrom.image/sme10/isolinux/* /build/smeserver/stage/$VERSION/x86_64/isolinux/ --exclude=CVS
      
Populate EFI
 
Populate EFI
 
  rsync -arv /mirrors/centos/7/os/x86_64/EFI /build/smeserver/stage/$VERSION/x86_64/
 
  rsync -arv /mirrors/centos/7/os/x86_64/EFI /build/smeserver/stage/$VERSION/x86_64/
  rsync -arv ~/smeserver/cdrom.image/sme10/EFI/* /build/smeserver/stage/$VERSION/x86_64/EFI/ --exclude=CVS
+
could also be from previous iso
 
+
  rsync -arv /build/smeserver/stage/$VERPREV/x86_64/EFI /build/smeserver/stage/$VERSION/x86_64/
populate netinstall
  −
rsync -arv ~/smeserver/cdrom.image/sme10/netinstall /build/smeserver/stage/$VERSION/x86_64/ --exclude=CVS
  −
populate Packages/base
  −
rsync -arv ~/smeserver/cdrom.image/sme10/
      
====Create cdrom content====
 
====Create cdrom content====
Line 89: Line 64:  
#Packages/base/comp.xml
 
#Packages/base/comp.xml
 
#isolinux{boot.msg, help.txt,isolinux.cfg}
 
#isolinux{boot.msg, help.txt,isolinux.cfg}
 +
#netinstall/isolinux/isolinux.cfg
 +
#product/.buildstamp
 
#updates/README.txt'''}}
 
#updates/README.txt'''}}
   Line 96: Line 73:  
  cvs -z3 -d:pserver:anonymous@shell.koozali.org:/cvs/smeserver co -P cdrom.image
 
  cvs -z3 -d:pserver:anonymous@shell.koozali.org:/cvs/smeserver co -P cdrom.image
   −
  rsync -rloDv --exclude 'CVS/'  ~/smeserver/cdrom.image/sme10/ /build/smeserver/stage/$VER/x86_64/
+
  rsync -arv --exclude 'CVS/'  ~/smeserver/cdrom.image/sme10/ /build/smeserver/stage/$VER/x86_64/
   −
====Create the remaining folders====
+
====Copy anaconda translations to create updates.img====
{{Note box|Note: TO DO translations in the updates image or move to product ?}}
+
Anaconda translations need copying to /updates/po from ~/anaconda-po
   −
* x86_64
+
  mkdir ~/anaconda-po/sme10
  cd /build/smeserver/stage/10/x86_64
+
  wget --mirror --no-parent -w 1 -A.mo -P ~/anaconda-po/sme10 https://translate.koozali.org/anaconda/sme10/
  mkdir -p /build/smeserver/stage/10/x86_64/repodata/
  −
mkdir -p /build/smeserver/stage/10/x86_64/updates/po
  −
mkdir -p /build/smeserver/stage/10/x86_64/updates/textw
  −
mkdir -p /build/smeserver/stage/10/x86_64/updates/iw
  −
mkdir -p /build/smeserver/stage/10/x86_64/updates/storage/devicelibs
  −
 
  −
* other directories
  −
mkdir -p /build/smeserver/stage/iso/$VER/{x86_64,source}
  −
 
  −
====Copy anaconda translations====
  −
Anaconda translations need copying to /updates/po from ~/anaconda-po
   
  cp -R ~/anaconda-po/translate.koozali.org/anaconda/sme10/* /build/smeserver/stage/10/x86_64/updates/po/
 
  cp -R ~/anaconda-po/translate.koozali.org/anaconda/sme10/* /build/smeserver/stage/10/x86_64/updates/po/
   −
====Copy anaconda content====
+
====Copy anaconda content to create product.img ====
 
See ~/smeserver/cdrom.image/sme10/updates/README.txt for details of what to copy. The patched anaconda files from ~/smeserver/rpms/anaconda/sme10 will go to updates directory. The exact directory depends on the anaconda version, eg  ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.56
 
See ~/smeserver/cdrom.image/sme10/updates/README.txt for details of what to copy. The patched anaconda files from ~/smeserver/rpms/anaconda/sme10 will go to updates directory. The exact directory depends on the anaconda version, eg  ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.56
    +
if first time running cvs (here example as anonymous, but can use your login):
 +
mkdir -p ~/smeserver
 +
pushd ~/smeserver
 +
cvs -z3 -d:pserver:anonymous@shell.koozali.org:/cvs/smeserver co -P rpms/anaconda
 +
popd
 +
 +
then you can simply
 
  pushd ~/smeserver/rpms/anaconda/sme10/
 
  pushd ~/smeserver/rpms/anaconda/sme10/
 
  cvs update -dPA
 
  cvs update -dPA
 
  make prep
 
  make prep
 
  popd
 
  popd
  cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.158/pyanaconda/bootloader.py /build/smeserver/stage/$VERSION/x86_64/product/usr/lib64/python2.7/site-packages/pyanaconda/
+
pushd /build/smeserver/stage/$VERSION/x86_64/product/
  cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.158/pyanaconda/installclasses/{fedora,centos,koozali}.py /build/smeserver/stage/$VERSION/x86_64/product/usr/lib64/python2.7/site-packages/pyanaconda/installclasses/
+
  cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.159/pyanaconda/installclasses/koozali.py run/install/product/pyanaconda/installclasses/
  cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.158/pyanaconda/packaging/yumpayload.py /build/smeserver/stage/$VERSION/x86_64/product/usr/lib64/python2.7/site-packages/pyanaconda/packaging/
+
  cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.159/pyanaconda/installclasses/koozali.py usr/lib64/python2.7/site-packages/pyanaconda/installclasses/
  cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.158/pyanaconda/installclasses/koozali.py /build/smeserver/stage/$VERSION/x86_64/product/run/install/product/pyanaconda/installclasses/
+
  cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.159/pyanaconda/installclasses/centos.py usr/lib64/python2.7/site-packages/pyanaconda/installclasses/
 +
  cp ~/smeserver/rpms/anaconda/sme10/anaconda-21.48.22.159/pyanaconda/installclasses/fedora.py usr/lib64/python2.7/site-packages/pyanaconda/installclasses/
 +
popd
    +
For testing purpose you can do this, but BUILD SCIPT DOES IT !
 +
build new product.img and copy it to stage, if you want but it should be done by the build.ISO script
 +
#find . | cpio -c -o | gzip -9cv > ../product.img; cd ..
 +
#mkdir -p /build/smeserver/stage/$VER/x86_64/images/
 +
#cp product.img /build/smeserver/stage/$VER/x86_64/images/
    
===='''Local Only''': Hack: Permission Fixup====
 
===='''Local Only''': Hack: Permission Fixup====
Line 143: Line 123:     
  VER=10
 
  VER=10
  VERSION=$VER.0.rc1
+
  VERSION=$VER.0
  VERPREV=$VER.0.beta1
+
  VERPREV=$VER.0.rc1
    
You can find logs of the related scripts build_ISO and build_installer<br />
 
You can find logs of the related scripts build_ISO and build_installer<br />
Line 180: Line 160:  
==Dev access to release ISO==
 
==Dev access to release ISO==
 
  VER=10
 
  VER=10
  VERSION=$VER.0.rc1
+
  VERSION=$VER.0
  VERPREV=$VER.0.beta1
+
  VERPREV=$VER.0.rc1
 +
# where is PREV could be "" "testing or "obsolete"
 +
FROM=testing
 +
# where we put new one could be "" "testing or "obsolete"
 +
TO=
    
=====Prepare directory structure for SME10 release=====
 
=====Prepare directory structure for SME10 release=====
 
SME 10.x test releases will go to /build/smeserver/repo/testing/10. Check that the link points to the correct testing release. Note when uploading Jigdos the ‘10’ link will not be pointing to the new directory.
 
SME 10.x test releases will go to /build/smeserver/repo/testing/10. Check that the link points to the correct testing release. Note when uploading Jigdos the ‘10’ link will not be pointing to the new directory.
  mkdir -p /build/smeserver/repo/testing/$VERSION/iso/source/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/iso/source/
  mkdir -p /build/smeserver/repo/testing/$VERSION/iso/x86_64/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/iso/x86_64/
  mkdir -p /build/smeserver/repo/testing/$VERSION/smeos/x86_64/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/smeos/x86_64/
    
=====Copy SME Server 10 64 bit Jigdo to mirror=====
 
=====Copy SME Server 10 64 bit Jigdo to mirror=====
  /bin/cp -a /build/smeserver/stage/iso/$VER/x86_64/smeserver-$VERSION-x86_64.jigdo /build/smeserver/repo/testing/$VERSION/iso/x86_64/
+
  /bin/cp -a /build/smeserver/stage/iso/$VER/x86_64/smeserver-$VERSION-x86_64.jigdo /build/smeserver/repo/$TO/$VERSION/iso/x86_64/
  /bin/cp -a /build/smeserver/stage/iso/$VER/x86_64/smeserver-$VERSION-x86_64.template /build/smeserver/repo/testing/$VERSION/iso/x86_64/
+
  /bin/cp -a /build/smeserver/stage/iso/$VER/x86_64/smeserver-$VERSION-x86_64.template /build/smeserver/repo/$TO/$VERSION/iso/x86_64/
  rsync -a --delete /build/smeserver/stage/$VER/x86_64/ /build/smeserver/repo/testing/$VERSION/smeos/x86_64/
+
  rsync -a --delete /build/smeserver/stage/$VER/x86_64/ /build/smeserver/repo/$TO/$VERSION/smeos/x86_64/
       
=====Copy SME Server 10 SRPMS Jigdo to mirror=====
 
=====Copy SME Server 10 SRPMS Jigdo to mirror=====
  /bin/cp -a /build/smeserver/stage/iso/$VER/source/smeserver-$VERSION-SRPMS.jigdo /build/smeserver/repo/testing/$VERSION/iso/source/
+
  /bin/cp -a /build/smeserver/stage/iso/$VER/source/smeserver-$VERSION-SRPMS.jigdo /build/smeserver/repo/$TO/$VERSION/iso/source/
  /bin/cp -a /build/smeserver/stage/iso/$VER/source/smeserver-$VERSION-SRPMS.template /build/smeserver/repo/testing/$VERSION/iso/source/
+
  /bin/cp -a /build/smeserver/stage/iso/$VER/source/smeserver-$VERSION-SRPMS.template /build/smeserver/repo/$TO/$VERSION/iso/source/
  rsync -a --delete /build/smeserver/stage/$VER/SRPMS/ /build/smeserver/repo/testing/$VERSION/smeos/SRPMS
+
  rsync -a --delete /build/smeserver/stage/$VER/SRPMS/ /build/smeserver/repo/$TO/$VERSION/smeos/SRPMS
    
=====Copy SME Server 10 ISOs to mirror=====
 
=====Copy SME Server 10 ISOs to mirror=====
  rsync -a --delete /build/smeserver/stage/iso/$VER/ /build/smeserver/repo/testing/$VERSION/iso
+
  rsync -a --delete /build/smeserver/stage/iso/$VER/ /build/smeserver/repo/$TO/$VERSION/iso
      Line 208: Line 192:  
  #this one already rsynced from stage
 
  #this one already rsynced from stage
 
  #cp -lr /build/smeserver/repo/testing/$VERPREV/smeos/* /build/smeserver/repo/testing/$VERSION/smeos/
 
  #cp -lr /build/smeserver/repo/testing/$VERPREV/smeos/* /build/smeserver/repo/testing/$VERSION/smeos/
  mkdir -p /build/smeserver/repo/testing/$VERSION/smeaddons/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/smeaddons/
  mkdir -p /build/smeserver/repo/testing/$VERSION/smecontribs/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/smecontribs/
  mkdir -p /build/smeserver/repo/testing/$VERSION/smedev/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/smedev/
  mkdir -p /build/smeserver/repo/testing/$VERSION/smeextras/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/smeextras/
  mkdir -p /build/smeserver/repo/testing/$VERSION/smetest/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/smetest/
  mkdir -p /build/smeserver/repo/testing/$VERSION/smeupdates/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/smeupdates/
  mkdir -p /build/smeserver/repo/testing/$VERSION/smeupdates-testing/
+
  mkdir -p /build/smeserver/repo/$TO/$VERSION/smeupdates-testing/
  cp -lr /build/smeserver/repo/testing/$VERPREV/smecontribs/* /build/smeserver/repo/testing/$VERSION/smecontribs/
+
  cp -lr /build/smeserver/repo/$FROM/$VERPREV/smecontribs/* /build/smeserver/repo/$TO/$VERSION/smecontribs/
  cp -lr /build/smeserver/repo/testing/$VERPREV/smedev/* /build/smeserver/repo/testing/$VERSION/smedev/
+
  cp -lr /build/smeserver/repo/$FROM/$VERPREV/smedev/* /build/smeserver/repo/$TO/$VERSION/smedev/
  cp -lr /build/smeserver/repo/testing/$VERPREV/smeextras/* /build/smeserver/repo/testing/$VERSION/smeextras/
+
  cp -lr /build/smeserver/repo/$FROM/$VERPREV/smeextras/* /build/smeserver/repo/$TO/$VERSION/smeextras/
  cp -lr /build/smeserver/repo/testing/$VERPREV/smetest/* /build/smeserver/repo/testing/$VERSION/smetest/
+
  cp -lr /build/smeserver/repo/$FROM/$VERPREV/smetest/* /build/smeserver/repo/$TO/$VERSION/smetest/
  cp -lr /build/smeserver/repo/testing/$VERPREV/smeupdates/* /build/smeserver/repo/testing/$VERSION/smeupdates/
+
  cp -lr /build/smeserver/repo/$FROM/$VERPREV/smeupdates/* /build/smeserver/repo/$TO/$VERSION/smeupdates/
  cp -lr /build/smeserver/repo/testing/$VERPREV/smeupdates-testing/* /build/smeserver/repo/testing/$VERSION/smeupdates-testing/
+
  cp -lr /build/smeserver/repo/$FROM/$VERPREV/smeupdates-testing/* /build/smeserver/repo/$TO/$VERSION/smeupdates-testing/
  cp -lr /build/smeserver/repo/testing/$VERPREV/smeaddons/* /build/smeserver/repo/testing/$VERSION/smeaddons/
+
  cp -lr /build/smeserver/repo/$FROM/$VERPREV/smeaddons/* /build/smeserver/repo/$TO/$VERSION/smeaddons/
    
=====Switch main version link=====
 
=====Switch main version link=====
 
and finally
 
and finally
   −
  rm -f  /build/smeserver/repo/testing/$VER
+
  rm -f  /build/smeserver/repo/$TO/$VER
  pushd /build/smeserver/repo/testing/
+
  pushd /build/smeserver/repo/$TO/
 
  ln -s $VERSION $VER
 
  ln -s $VERSION $VER
 
  popd
 
  popd
 +
 +
 +
Addendum: for being able to keep on releasing new package with shell some modification will be necessary with exports.
    
[[Category:SME Server Development Framework]]
 
[[Category:SME Server Development Framework]]
 
[[Category:Development Tools]]
 
[[Category:Development Tools]]
Super Admin, Wiki & Docs Team, Bureaucrats, Interface administrators, Administrators
3,250

edits

Navigation menu