[DEPRECATED, use docker as replacement] Install RPM Based Distros, e.g. SuSE or Fedora, in chroots (for schroot) in an Ubuntu. This is the old method, now I'm using docker.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

45 lines
1.2 KiB

9 years ago
#!/bin/bash -e
if test -f /etc/setup-susebootstrap.conf; then
. /etc/setup-susebootstrap.conf
fi
user=${user:-"${USER},jenkins"}
if test ${#distros[@]} -lt 1; then
distros=( opensuse
fedora
centos )
fi
if test ${#distros[@]} -ne ${#archs[@]}; then
archs=( "i586 x86_64"
"i686 x86_64"
"x86_64" )
fi
if test ${#distros[@]} -ne ${#versions[@]}; then
versions=( "13.2 13.1 tumbleweed"
"22 21"
"7 6 5" )
fi
for ((i=0; i<${#distros[@]}; ++i)); do
distro=${distros[$i]}
for arch in ${archs[$i]}; do
case $arch in
i?86) basearch=i386;;
*) basearch=$arch;;
esac
for version in ${versions[$i]}; do
echo "******** update $distro $version $basearch ********" 1>&2
if ! test -d /var/chroot/${distro}-${version}_${basearch}; then
echo " ---- install schroot $distro $version $arch" 1>&2
sudo VERSION=${version} HW="${arch} noarch" \
SCHROOTUSER="$user" \
OS=${distro} \
ADDITIONAL-DEFINITIONS=${additional_definitions} \
susebootstrap.sh $*
fi
done
done
done