aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/config-blacklist-module.sh
blob: e490a83aac9bf6fc041cbe341b24f4aa5a0efdda (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh

image="$1"
module="$2"

if test "$image" = ""; then
	echo "usage: $0 <image> <module>"
	exit 1
fi

set -ex
virt-customize -a "$image" --no-network \
	--edit "/boot/extlinux/extlinux.conf:s/append/append rd.driver.blacklist=${module}/" \
	--write "/etc/modprobe.d/blacklist-${module}.conf:blacklist ${module}"