a2d8f0191e
Get each charm up to date with lp:charm-helpers for release testing. Change-Id: I3fd359025a7be468fcc856cab7f42894a318e90f
14 lines
406 B
Python
14 lines
406 B
Python
import subprocess
|
|
|
|
|
|
def persistent_modprobe(module):
|
|
"""Load a kernel module and configure for auto-load on reboot."""
|
|
with open('/etc/modules', 'r+') as modules:
|
|
if module not in modules.read():
|
|
modules.write(module + "\n")
|
|
|
|
|
|
def update_initramfs(version='all'):
|
|
"""Updates an initramfs image."""
|
|
return subprocess.check_call(["update-initramfs", "-k", version, "-u"])
|