Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
alpine-conf
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
18
Issues
18
List
Boards
Labels
Service Desk
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
alpine
alpine-conf
Commits
abaaa064
Commit
abaaa064
authored
Jun 21, 2012
by
Natanael Copa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
setup-disk: fix install of xen dom0
ref #1213
parent
cda38306
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
11 deletions
+8
-11
setup-disk.in
setup-disk.in
+8
-11
No files found.
setup-disk.in
View file @
abaaa064
...
...
@@ -73,10 +73,6 @@ is_vmware() {
||
grep
-q
VMware /proc/ide/hd
*
/model 2>/dev/null
}
is_xen
()
{
[
-d
/proc/xen
]
}
# return true (0) if given device is lvm
is_lvm
()
{
lvs
"
$1
"
>
/dev/null 2>&1
...
...
@@ -250,15 +246,15 @@ install_mounted_root() {
if
is_vmware
;
then
kernel_opts
=
"pax_nouderef
$kernel_opts
"
fi
if
is_xen
;
then
kernel_opts
=
"xen
$kernel_opts
"
fi
modules
=
"sd-mod,usb-storage,
${
root_fs
}${
raidmod
}
"
sed
-e
"s:^root=.*:root=
$root
:"
\
-e
"s:^default_kernel_opts=.*:default_kernel_opts=
\"
$kernel_opts
\"
:"
\
-e
"s:^modules=.*:modules=
$modules
:"
\
/etc/update-extlinux.conf
>
"
$mnt
"
/etc/update-extlinux.conf
if
[
"
$(
rc
--sys
)
"
=
"XEN0"
]
;
then
sed
-i
-e
"s:^default=.*:default=xen-grsec:"
\
"
$mnt
"
/etc/update-extlinux.conf
fi
# generate the fstab
if
[
-f
"
$mnt
"
/etc/fstab
]
;
then
...
...
@@ -282,6 +278,9 @@ EOF
local
apkflags
=
"--initdb --quiet --progress --update-cache --clean-protected"
local
pkgs
=
$(
cat
"
$mnt
"
/etc/apk/world
"
$mnt
"
/var/lib/apk/world 2>/dev/null
)
pkgs
=
"
$pkgs
acct linux-
$KERNEL_FLAVOR
alpine-base"
if
[
"
$(
rc
--sys
)
"
=
"XEN0"
]
;
then
pkgs
=
"
$pkgs
xen-hypervisor"
fi
local
repos
=
$(
sed
-e
's/\#.*//'
/etc/apk/repositories
)
local
repoflags
=
for
i
in
$repos
;
do
...
...
@@ -291,9 +290,7 @@ EOF
apk add
--root
"
$mnt
"
$apkflags
--overlay-from-stdin
\
$repoflags
$pkgs
<
$ovlfiles
>
/dev/null
||
return
1
echo
""
if
!
is_xen
;
then
extlinux
$extlinux_raidopt
--install
"
$mnt
"
/boot
fi
extlinux
$extlinux_raidopt
--install
"
$mnt
"
/boot
}
unmount_partitions
()
{
...
...
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