From 6adca87433dbd910a12155e5d779cc454d49bc1b Mon Sep 17 00:00:00 2001 From: Frank Brehm Date: Fri, 29 Jan 2016 17:02:45 +0100 Subject: [PATCH] Update of generation of Ubuntu chroots --- create-chroots | 42 ++++++++++++++++++------------------------ 1 file changed, 18 insertions(+), 24 deletions(-) diff --git a/create-chroots b/create-chroots index 8ceab3c..7df64a3 100755 --- a/create-chroots +++ b/create-chroots @@ -101,29 +101,31 @@ CHROOT_INI_UBUNTU=$( cat <<-END SRC_LIST_DEBIAN=$( cat <<-END deb http://ftp-stud.hs-esslingen.de/debian {{distro}} main non-free contrib - deb-src http://ftp-stud.hs-esslingen.de/debian {{distro}} main non-free contrib deb http://security.debian.org/ {{distro}}/updates main contrib non-free - deb-src http://security.debian.org/ {{distro}}/updates main contrib non-free # {{distro}}-updates, previously known as 'volatile' deb http://ftp-stud.hs-esslingen.de/debian/ {{distro}}-updates main contrib non-free - deb-src http://ftp-stud.hs-esslingen.de/debian/ {{distro}}-updates main contrib non-free END ) SRC_LIST_DEBIAN_BACKPORTS=$( cat <<-END - # jessie-backports, previously on backports.debian.org - deb http://ftp-stud.hs-esslingen.de/debian/ jessie-backports main contrib non-free - deb-src http://ftp-stud.hs-esslingen.de/debian/ jessie-backports main contrib non-free + # {{distro}}-backports, previously on backports.debian.org + deb http://ftp-stud.hs-esslingen.de/debian/ {{distro}}-backports main contrib non-free END ) -PB_SRC_LIST_UBUNTU=$( cat <<-END - deb http://repo.pb.local/pb-ubuntu {{distro}} main restricted - deb http://repo.pb.local/pb-ubuntu {{distro}}-proposed main restricted +SRC_LIST_UBUNTU=$( cat <<-END + deb http://ftp-stud.hs-esslingen.de/ubuntu {{distro}} main restricted universe multiverse + + # {{distro}}-updates + deb http://ftp-stud.hs-esslingen.de/ubuntu/ {{distro}}-updates main restricted universe multiverse + + # {{distro}}-backports + deb http://ftp-stud.hs-esslingen.de/ubuntu/ {{distro}}-backports main restricted universe multiverse + END ) @@ -348,11 +350,10 @@ do_ubuntu() { for distro in ${do_distros} ; do - local chroot="pb-${distro}" + local chroot="fb-${distro}" local path="${ROOT_PATH}/${chroot}" local ini_file="/etc/schroot/chroot.d/${chroot}" local sources_list="${path}/etc/apt/sources.list" - local pb_sources_list="${path}/etc/apt/sources.list.d/profitbricks.list" local proxy_file="${path}/etc/apt/apt.conf.d/80proxy" echo @@ -373,23 +374,16 @@ do_ubuntu() { -e "s/{{vendor}}/Debian/g" | \ ${SUDO} tee "${ini_file}" >/dev/null -# echo "Updating ${pb_sources_list} ..." -# echo "${PB_SRC_LIST_UBUNTU}" | \ -# sed -e "s/{{distro}}/${distro}/g" | \ -# ${SUDO} tee "${pb_sources_list}" >/dev/null + echo "Updating ${sources_list} ..." + echo "${SRC_LIST_UBUNTU}" | \ + sed -e "s/{{distro}}/${distro}/g" | \ + ${SUDO} tee "${sources_list}" >/dev/null + echo "" | ${SUDO} tee -a "${sources_list}" >/dev/null # echo "Updating ${proxy_file} ..." # echo "${PROXY_FILE_CONTENT}" | ${SUDO} tee "${proxy_file}" >/dev/null -# echo -# echo "Checking profitbricks keyring ..." -# if schroot -d / -u root -c source:${chroot} -- dpkg -s profitbricks-keyring >/dev/null 2>&1 ; then -# : -# else -# echo "Adding profitbricks keyring ..." -# schroot -d / -u root -c source:${chroot} -- apt-get update -## schroot -d / -u root -c source:${chroot} -- apt-get -y --allow-unauthenticated install profitbricks-keyring -# fi + schroot -c source:${chroot} -u root -d /root -- bash -c "apt-get update && apt-get clean" done -- 2.39.5