diff options
| author | Sean Whitton <spwhitton@spwhitton.name> | 2016-06-11 20:35:09 +0900 |
|---|---|---|
| committer | Sean Whitton <spwhitton@spwhitton.name> | 2016-06-12 09:34:37 +0900 |
| commit | 6bfcb080bf5b0eb0ed7bf9d908c298d664570bf1 (patch) | |
| tree | 86b31885c83d1bc84ac31f67176668ed5d6803e1 /src/Propellor/Property/HostingProvider | |
| parent | 942a65ab9f9847897abbd2c8515f349465c33843 (diff) | |
Exoscale.distroKernel
Diffstat (limited to 'src/Propellor/Property/HostingProvider')
| -rw-r--r-- | src/Propellor/Property/HostingProvider/Exoscale.hs | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/Propellor/Property/HostingProvider/Exoscale.hs b/src/Propellor/Property/HostingProvider/Exoscale.hs new file mode 100644 index 00000000..afa3e1b7 --- /dev/null +++ b/src/Propellor/Property/HostingProvider/Exoscale.hs @@ -0,0 +1,23 @@ +-- | Maintainer: Sean Whitton <spwhitton@spwhitton.name> + +module Propellor.Property.HostingProvider.Exoscale ( + distroKernel, +) where + +import Propellor.Base +import qualified Propellor.Property.Grub as Grub +import qualified Propellor.Property.Apt as Apt +import qualified Propellor.Property.Reboot as Reboot + +-- | Current Exoshare Debian image doesn't install GRUB, so this property makes +-- sure GRUB is installed and we're running the distro's kernel +-- +-- We reboot after doing this because 'Sbuild.built' will fail to set up an +-- overlay-type chroot on an old kernel +distroKernel :: Architecture -> Property DebianLike +distroKernel arch = Grub.installed' Grub.PC + `before` Apt.installed ["linux-image-" ++ arch] + `before` Grub.boots "/dev/vda" + `before` Grub.mkConfig + `before` Reboot.now + `flagFile` "/etc/propellor-grub" |
