bundles/zfs: support arch linux
This commit is contained in:
parent
961a2891a0
commit
c1bb43286d
2 changed files with 39 additions and 23 deletions
|
@ -3,25 +3,26 @@ from json import dumps
|
|||
|
||||
from bundlewrap.metadata import MetadataJSONEncoder
|
||||
|
||||
actions = {
|
||||
# For some reason, this module doesn't get auto-loaded on debian,
|
||||
# even if installation of zfsutils-linux tries to start
|
||||
# zfs-mount.service. We have no choice but to do it manually.
|
||||
'modprobe_zfs': {
|
||||
'command': 'modprobe zfs',
|
||||
'unless': 'lsmod | grep ^zfs',
|
||||
'needs': {
|
||||
'pkg_apt:zfs-dkms',
|
||||
if node.os == 'debian':
|
||||
actions = {
|
||||
# For some reason, this module doesn't get auto-loaded on debian,
|
||||
# even if installation of zfsutils-linux tries to start
|
||||
# zfs-mount.service. We have no choice but to do it manually.
|
||||
'modprobe_zfs': {
|
||||
'command': 'modprobe zfs',
|
||||
'unless': 'lsmod | grep ^zfs',
|
||||
'needs': {
|
||||
'pkg_apt:zfs-dkms',
|
||||
},
|
||||
'needed_by': {
|
||||
'pkg_apt:zfs-zed',
|
||||
'pkg_apt:zfsutils-linux',
|
||||
'zfs_dataset:',
|
||||
'zfs_pool:',
|
||||
},
|
||||
'comment': 'If this fails, do a dist-upgrade, reinstall zfs-dkms, reboot',
|
||||
},
|
||||
'needed_by': {
|
||||
'pkg_apt:zfs-zed',
|
||||
'pkg_apt:zfsutils-linux',
|
||||
'zfs_dataset:',
|
||||
'zfs_pool:',
|
||||
},
|
||||
'comment': 'If this fails, do a dist-upgrade, reinstall zfs-dkms, reboot',
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
files = {
|
||||
'/etc/modprobe.d/zfs.conf': {
|
||||
|
@ -69,11 +70,7 @@ files = {
|
|||
}
|
||||
|
||||
svc_systemd = {
|
||||
'zfs-zed': {
|
||||
'needs': {
|
||||
'pkg_apt:zfs-zed'
|
||||
},
|
||||
},
|
||||
'zfs-zed': {},
|
||||
}
|
||||
|
||||
for name, attrs in node.metadata.get('zfs/datasets', {}).items():
|
||||
|
|
|
@ -16,6 +16,7 @@ defaults = {
|
|||
},
|
||||
'zfs-zed': {
|
||||
'needed_by': {
|
||||
'svc_systemd:zfs-zed',
|
||||
'zfs_dataset:',
|
||||
'zfs_pool:',
|
||||
},
|
||||
|
@ -58,6 +59,24 @@ defaults = {
|
|||
},
|
||||
},
|
||||
},
|
||||
'pacman': {
|
||||
'additional_config': {
|
||||
'[archzfs]\nServer = http://archzfs.com/archzfs/x86_64',
|
||||
},
|
||||
'packages': {
|
||||
'zfs-linux-lts': {
|
||||
'needed_by': {
|
||||
'zfs_dataset:',
|
||||
'zfs_pool:',
|
||||
},
|
||||
},
|
||||
'zfs-utils': {
|
||||
'needed_by': {
|
||||
'svc_systemd:zfs-zed',
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
'zfs': {
|
||||
'datasets': {},
|
||||
'pools': {},
|
||||
|
|
Loading…
Reference in a new issue