Commit e34345cb authored by Nikos Skalkotos's avatar Nikos Skalkotos
Browse files

Update multistrap to create a wheezy helper

Repo and version pinning does not work yet
parent fc8cbf90
......@@ -17,23 +17,18 @@ unpack=true
# the order of sections is not important.
# the debootstrap option determines which repository
# is used to calculate the list of Priority: required packages.
debootstrap=Debian Backport GRNet
aptsources=Debian Backport
debootstrap=Debian GRNet
aptsources=Debian
[Debian]
packages=linux-image-amd64 linux-image-xen-amd64 socat iproute xenstore-utils ntfsprogs xmlstarlet python reglookup chntpw parted python-support
packages=linux-image-amd64 xen-linux-system-amd64 socat iproute xenstore-utils ntfsprogs xmlstarlet python reglookup chntpw parted python-support eatmydata gdisk ntfs-3g
source=http://ftp.gr.debian.org/debian
suite=squeeze
[Backport]
packages=eatmydata gdisk
source=http://backports.debian.org/debian-backports
suite=squeeze-backports
suite=wheezy
[GRNet]
packages=snf-image-helper ntfs-3g ufsutils
packages=snf-image-helper ufsutils
# Don't change the parameters below unless you really know what you are doing.
# The /'s and the empty `componets' variable are needed when working with apt2.
source=http://apt2.dev.grnet.gr/
suite=stable/
# The /'s and the empty `componets' variable are needed when working with apt.
source=http://apt.dev.grnet.gr/
suite=wheezy/
components=
......@@ -87,8 +87,6 @@ cat >&1 <<EOF
This program will overwrite the following files if present:
\`$HELPER_DIR/initrd'
\`$HELPER_DIR/kernel'
\`$HELPER_DIR/initrd-xen'
\`$HELPER_DIR/kernel-xen'
\`$HELPER_DIR/image'
\`$HELPER_DIR/packages'
EOF
......@@ -176,23 +174,13 @@ shopt -s extglob
kernel=$(ls "$target"/boot/vmlinuz-+([0-9.])-+([a-z0-9])-amd64)
initrd=$(ls "$target"/boot/initrd.img-+([0-9.])-+([a-z0-9])-amd64)
kernel_xen=$(ls "$target"/boot/vmlinuz-+([0-9.])-+([a-z0-9])-xen-amd64)
initrd_xen=$(ls "$target"/boot/initrd.img-+([0-9.])-+([a-z0-9])-xen-amd64)
echo "Moving $(basename "$kernel") and $(basename "$initrd") to \`$HELPER_DIR'"
cp "$kernel" "$initrd" "$HELPER_DIR"
echo "Moving $(basename "$kernel_xen") and $(basename "$initrd_xen") to \`$HELPER_DIR'"
cp "$kernel_xen" "$initrd_xen" "$HELPER_DIR"
kernel=$(basename "$kernel")
initrd=$(basename "$initrd")
kernel_xen=$(basename "$kernel_xen")
initrd_xen=$(basename "$initrd_xen")
(cd "$HELPER_DIR"; ln -fs "$kernel" kernel; ln -fs "$initrd" initrd)
(cd "$HELPER_DIR"; ln -fs "$kernel_xen" kernel-xen; ln -fs "$initrd_xen" initrd-xen)
pkg_installed=$(grep snf-image-helper "$HELPER_DIR/packages" > /dev/null && echo yes)
......
......@@ -64,8 +64,6 @@ $(basename $0) will download a suitable snf-image-helper image and will install
it under $IMAGE_DIR. The following files will be overwritten if present:
\`$HELPER_DIR/initrd'
\`$HELPER_DIR/kernel'
\`$HELPER_DIR/initrd-xen'
\`$HELPER_DIR/kernel-xen'
\`$HELPER_DIR/image'
\`$HELPER_DIR/packages'
EOF
......
......@@ -31,7 +31,7 @@ launch_helper() {
echo "$($DATE +%Y:%m:%d-%H:%M:%S.%N) VM START" >&2
xm create /dev/null \
kernel="$HELPER_DIR/kernel-xen" ramdisk="$HELPER_DIR/initrd-xen" \
kernel="$HELPER_DIR/kernel" ramdisk="$HELPER_DIR/initrd" \
root="/dev/xvda1" memory="256" boot="c" vcpus=1 name="$name" \
extra="console=hvc0 hypervisor=$HYPERVISOR snf_image_activate_helper \
ipv6.disable=1 rules_dev=/dev/xvdc ro boot=local helper_ip=10.0.0.1 \
......
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