git.annexia.org
/
libguestfs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Version 1.14.5.
[libguestfs.git]
/
images
/
guest-aux
/
make-fedora-img.sh
diff --git
a/images/guest-aux/make-fedora-img.sh
b/images/guest-aux/make-fedora-img.sh
index
3198930
..
b4c07e9
100755
(executable)
--- a/
images/guest-aux/make-fedora-img.sh
+++ b/
images/guest-aux/make-fedora-img.sh
@@
-1,6
+1,6
@@
#!/bin/bash -
# libguestfs
#!/bin/bash -
# libguestfs
-# Copyright (C) 2010 Red Hat Inc.
+# Copyright (C) 2010
-2011
Red Hat Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@
-14,7
+14,7
@@
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
-# Foundation, Inc.,
675 Mass Ave, Cambridge, MA 02139,
USA.
+# Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
USA.
# Make a standard test image which is used by all the tools test
# scripts. This test image is supposed to look like a Fedora
# Make a standard test image which is used by all the tools test
# scripts. This test image is supposed to look like a Fedora
@@
-31,7
+31,7
@@
LABEL=ROOT / ext2 default 0 0
EOF
# Create a disk image.
EOF
# Create a disk image.
-../
fish/guestfish <<'EOF'
+../
run ../fish/guestfish <<EOF
sparse fedora.img.tmp 512M
run
sparse fedora.img.tmp 512M
run
@@
-48,12
+48,12
@@
lvcreate LV2 VG 32
lvcreate LV3 VG 64
# Phony /boot filesystem.
lvcreate LV3 VG 64
# Phony /boot filesystem.
-mkfs-
b ext2 4096 /dev/sda1
+mkfs-
opts ext2 /dev/sda1 blocksize:4096
set-e2label /dev/sda1 BOOT
set-e2uuid /dev/sda1 01234567-0123-0123-0123-012345678901
# Phony root filesystem.
set-e2label /dev/sda1 BOOT
set-e2uuid /dev/sda1 01234567-0123-0123-0123-012345678901
# Phony root filesystem.
-mkfs-
b ext2 4096 /dev/VG/Root
+mkfs-
opts ext2 /dev/VG/Root blocksize:4096
set-e2label /dev/VG/Root ROOT
set-e2uuid /dev/VG/Root 01234567-0123-0123-0123-012345678902
set-e2label /dev/VG/Root ROOT
set-e2uuid /dev/VG/Root 01234567-0123-0123-0123-012345678902
@@
-73,8
+73,9
@@
write /etc/fedora-release "Fedora release 14 (Phony)"
write /etc/sysconfig/network "HOSTNAME=fedora.invalid"
upload guest-aux/fedora-name.db /var/lib/rpm/Name
write /etc/sysconfig/network "HOSTNAME=fedora.invalid"
upload guest-aux/fedora-name.db /var/lib/rpm/Name
+upload guest-aux/fedora-packages.db /var/lib/rpm/Packages
-upload bin-x86_64-dynamic /bin/ls
+upload
${SRCDIR}/
bin-x86_64-dynamic /bin/ls
mkdir /boot/grub
touch /boot/grub/grub.conf
mkdir /boot/grub
touch /boot/grub/grub.conf
@@
-82,6
+83,14
@@
touch /boot/grub/grub.conf
# Test files.
write /etc/test1 "abcdefg"
write /etc/test2 ""
# Test files.
write /etc/test1 "abcdefg"
write /etc/test2 ""
+upload -<<__end /etc/test3
+a
+b
+c
+d
+e
+f
+__end
write /bin/test1 "abcdefg"
write /bin/test2 "zxcvbnm"
write /bin/test3 "1234567"
write /bin/test1 "abcdefg"
write /bin/test2 "zxcvbnm"
write /bin/test3 "1234567"
@@
-92,9
+101,9
@@
mknod 0777 10 10 /bin/test7
# Other filesystems.
# Note that these should be empty, for testing virt-df.
# Other filesystems.
# Note that these should be empty, for testing virt-df.
-mkfs-
b ext2 4096 /dev/VG/LV1
-mkfs-
b ext2 1024 /dev/VG/LV2
-mkfs-
b ext2 2048 /dev/VG/LV3
+mkfs-
opts ext2 /dev/VG/LV1 blocksize:4096
+mkfs-
opts ext2 /dev/VG/LV2 blocksize:1024
+mkfs-
opts ext2 /dev/VG/LV3 blocksize:2048
EOF
rm fstab.tmp
EOF
rm fstab.tmp