Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itminedu
snf-image
Commits
e34345cb
Commit
e34345cb
authored
Sep 09, 2013
by
Nikos Skalkotos
Browse files
Update multistrap to create a wheezy helper
Repo and version pinning does not work yet
parent
fc8cbf90
Changes
4
Hide whitespace changes
Inline
Side-by-side
snf-image-host/multistrap.conf
View file @
e34345cb
...
...
@@ -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
-
3
g
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
-
3
g
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 apt
2
.
source
=
http
://
apt
2
.
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
=
snf-image-host/snf-image-create-helper.in
View file @
e34345cb
...
...
@@ -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
)
...
...
snf-image-host/snf-image-update-helper.in
View file @
e34345cb
...
...
@@ -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
...
...
snf-image-host/xen-common.sh
View file @
e34345cb
...
...
@@ -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
\
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment