#! /bin/sh . $MYPWD/locations.include # Hacked by bv@bnl.gov from the originals at # Hacked by csieh@fnal.gov from the originals at # ftp://apt.tuxfamily.org/pub/ftp.tuxfamily.org/apt-rpm/scripts/ # to be more generic. # Relative directory from the top of the apt repository to the top of the mirror #MIRRORDIR=../mirror MIRRORDIR=. # Extra PATH for genbasedir/genpkglist etc #export PATH=/data/www/org/y/l/tuxfamily.org/m/p/apt/htdocs/scripts:$PATH export PATH=$RELEASEDIR/scripts:$PATH # The idea of full/all/quick is: # * the first time you create the apt repository, choose "full". # * each night (when updates are downloaded), relaunch with "quick" # * if extra packages are put in 'extra' repository, relaunch with "quick" # * if the main os packages change (should not), use "all" if [ $# -ne 2 -o \( "$1" != "full" -a "$1" != "all" -a "$1" != "quick" \) ]; then echo "Usage: $0 " echo " is one of:" echo " \"full\": full apt repository creation" echo " \"all\": no apt repository creation, but full indexes regeneration" echo " \"quick\": no apt repository creation, only updates indexes regeneration" exit 1 fi MODE=$1 DISCNUM=$2 #GETTING APTVERSION AND DEFAULT and RELEASEDIR from locations.include if [ "$MODE" = "full" ]; then # Create directories mkdir -p $RELEASEDIR/$DISCNUM/apt/base || exit 1 # Create the main release file cat >$RELEASEDIR/$DISCNUM/apt/base/release <$RELEASEDIR/$DISCNUM/apt/base/release.os <$RELEASEDIR/$DISCNUM/apt/base/release.contrib <$RELEASEDIR/$DISCNUM/apt/base/release.notsupported <$RELEASEDIR/$DISCNUM/apt/base/release.srpms <