Safe Haskell | None |
---|---|
Language | Haskell98 |
- debootstrapped :: DebootstrapConfig -> FilePath -> Chroot
- bootstrapped :: ChrootBootstrapper b => b -> FilePath -> Chroot
- provisioned :: Chroot -> RevertableProperty HasInfo
- data Chroot where
- Chroot :: ChrootBootstrapper b => FilePath -> b -> Host -> Chroot
- class ChrootBootstrapper b where
- data Debootstrapped = Debootstrapped DebootstrapConfig
- data ChrootTarball = ChrootTarball FilePath
- noServices :: RevertableProperty NoInfo
- inChroot :: Propellor Bool
- provisioned' :: (Property HasInfo -> Property HasInfo) -> Chroot -> Bool -> RevertableProperty HasInfo
- propagateChrootInfo :: IsProp (Property i) => Chroot -> Property i -> Property HasInfo
- propellChroot :: Chroot -> ([String] -> IO (CreateProcess, IO ())) -> Bool -> Property NoInfo
- chain :: [Host] -> CmdLine -> IO ()
- chrootSystem :: Chroot -> Maybe System
Documentation
debootstrapped :: DebootstrapConfig -> FilePath -> Chroot Source
Defines a Chroot at the given location, built with debootstrap.
Properties can be added to configure the Chroot. At a minimum,
add the os
property to specify the operating system to bootstrap.
debootstrapped Debootstrap.BuildD "/srv/chroot/ghc-dev" & os (System (Debian Unstable) "amd64") & Apt.installed ["ghc", "haskell-platform"] & ...
bootstrapped :: ChrootBootstrapper b => b -> FilePath -> Chroot Source
Defines a Chroot at the given location, bootstrapped with the specified ChrootBootstrapper.
provisioned :: Chroot -> RevertableProperty HasInfo Source
Ensures that the chroot exists and is provisioned according to its properties.
Reverting this property removes the chroot. Anything mounted inside it is first unmounted. Note that it does not ensure that any processes that might be running inside the chroot are stopped.
Specification of a chroot. Normally you'll use debootstrapped
or
bootstrapped
to construct a Chroot value.
Chroot :: ChrootBootstrapper b => FilePath -> b -> Host -> Chroot |
class ChrootBootstrapper b where Source
Class of things that can do initial bootstrapping of an operating System in a chroot.
data Debootstrapped Source
Use this to bootstrap a chroot with debootstrap.
data ChrootTarball Source
Use this to bootstrap a chroot by extracting a tarball.
The tarball is expected to contain a root directory (no top-level
directory, also known as a "tarbomb").
It may be optionally compressed with any format tar
knows how to
detect automatically.
noServices :: RevertableProperty NoInfo Source
Adding this property to a chroot prevents daemons and other services from being started, which is often something you want to prevent when building a chroot.
This is accomplished by installing a /usr/sbin/policy-rc.d script that does not let any daemons be started by packages that use invoke-rc.d. Reverting the property removes the script.
inChroot :: Propellor Bool Source
Check if propellor is currently running within a chroot.
This allows properties to check and avoid performing actions that should not be done in a chroot.
Internal use
provisioned' :: (Property HasInfo -> Property HasInfo) -> Chroot -> Bool -> RevertableProperty HasInfo Source
propellChroot :: Chroot -> ([String] -> IO (CreateProcess, IO ())) -> Bool -> Property NoInfo Source
Propellor is run inside the chroot to provision it.
chrootSystem :: Chroot -> Maybe System Source