summaryrefslogtreecommitdiff
path: root/setup-xen-dom0.in
blob: a05ccc9c314b53d9849f688e41940082bf8a24fe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/sh

# simple script to setup basic xen dom0

# kernel modules
mkdir -p "$ROOT"/etc
for mod in xen_netback xen_blkback xenfs xen_pciback xen_wdt tun; do
	if $MOCK modprobe $mod; then
		grep -q -w $mod "$ROOT"/etc/modules 2>/dev/null || echo $mod >> "$ROOT"/etc/modules
	fi
done

# install packages
apk add --quiet xen

# setup and start services
for svc in xenstored xenconsoled xenqemu; do
	rc-update --quiet add $svc default
done

rc-service xenstored start
rc-service xenconsoled start
rc-service xenqemu start