Commit 9ca45aea authored by Ophélie Gagnard's avatar Ophélie Gagnard

build-scripts/: Backup bin/buildout and restore it so that it is not...

build-scripts/: Backup bin/buildout and restore it so that it is not "rebootstraped" when sent to OBS.
parent f5e2cff9
...@@ -16,5 +16,9 @@ mkdir -p $RUN_BUILDOUT_DIR ...@@ -16,5 +16,9 @@ mkdir -p $RUN_BUILDOUT_DIR
cd $RUN_BUILDOUT_DIR cd $RUN_BUILDOUT_DIR
# should be with gcc here and without in OBS # should be with gcc here and without in OBS
cp $TEMPLATE_DIR/tmp/buildout_without_gcc.cfg buildout.cfg cp $TEMPLATE_DIR/tmp/buildout_without_gcc.cfg buildout.cfg
(python2.7 -S bootstrap-buildout.py --buildout-version 2.7.1+slapos016 --setuptools-version 44.1.1 --setuptools-to-dir eggs -f http://www.nexedi.org/static/packages/source/slapos.buildout/ && ./bin/buildout -v) ## next line explained
# 1st cmd: bootstrap buildout (creates bin/buildout)
# 2nd cmd: backup bin/buildout (to be restored for OBS)
# 3rd cmd: run buildout (which apparently modifies itself)
(python2.7 -S bootstrap-buildout.py --buildout-version 2.7.1+slapos016 --setuptools-version 44.1.1 --setuptools-to-dir eggs -f http://www.nexedi.org/static/packages/source/slapos.buildout/ && cp bin/buildout bin/backup.buildout && ./bin/buildout -v)
#cp $TEMPLATE_DIR/tmp/buildout_with_gcc.cfg buildout.cfg #cp $TEMPLATE_DIR/tmp/buildout_with_gcc.cfg buildout.cfg
...@@ -12,6 +12,9 @@ echo TMP_DIR = $TMP_DIR ...@@ -12,6 +12,9 @@ echo TMP_DIR = $TMP_DIR
cp $TEMPLATE_DIR/tmp/Makefile $TARBALL_DIR/Makefile cp $TEMPLATE_DIR/tmp/Makefile $TARBALL_DIR/Makefile
# save the local TARBALL_DIR to replace it with the TARBALL_DIR of OBS' VM # save the local TARBALL_DIR to replace it with the TARBALL_DIR of OBS' VM
echo $TARBALL_DIR > $TARBALL_DIR/cache_creation_build_directory echo $TARBALL_DIR > $TARBALL_DIR/cache_creation_build_directory
# restore bin/buildout
# note: when installing python, buildout "rebootstrap" itself to use the installed python: it would fail on OBS' VM
mv $RUN_BUILDOUT_DIR/bin/backup.buildout $RUN_BUILDOUT_DIR/bin/buildout
# clean the parts directory # clean the parts directory
rm -rf $RUN_BUILDOUT_DIR/{.installed.cfg,parts/} rm -rf $RUN_BUILDOUT_DIR/{.installed.cfg,parts/}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment