From f461520797bc9e612c898d8c1ffaf2d35dd02ccb Mon Sep 17 00:00:00 2001 From: Arnaud Gomes <Arnaud.Gomes@ircam.fr> Date: Mon, 8 Apr 2013 17:44:42 +0200 Subject: [PATCH] Enable zfs service and make sure DKMS can build kernel modules. --- manifests/init.pp | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/manifests/init.pp b/manifests/init.pp index 0860c21..1037e4e 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -26,6 +26,14 @@ class zfs { if $::operatingsystem in ['RedHat', 'CentOS', 'Scientific'] { + + # We need kernel-headers for DKMS. + if !defined(Package['kernel-headers']) { + package { 'kernel-headers': + ensure => $::kernelrelease, + } + } + package { 'zfs-release': ensure => present, provider => rpm, @@ -33,7 +41,12 @@ class zfs { } -> package { 'zfs': ensure => present, + } ~> + service { 'zfs': + ensure => running, + enable => true, } + } } -- GitLab