b9-0.5.15: A tool and library for building virtual machine images.

Safe HaskellNone
LanguageHaskell2010

B9.ArtifactGeneratorImpl

Description

Mostly effectful functions to assemble artifacts.

Synopsis

Documentation

getArtifactOutputFiles :: ArtifactGenerator -> Either String [FilePath] Source

Return a list of relative paths for the local files to be generated by the ArtifactGenerator. This excludes Shared and Transient image targets.

assemble :: ArtifactGenerator -> B9 [AssembledArtifact] Source

Run an artifact generator to produce the artifacts.

evalArtifactGenerator :: String -> String -> BuildVariables -> ArtifactGenerator -> Either String [InstanceGenerator [SourceGenerator]] Source

Evaluate an ArtifactGenerator into a list of low-level build instructions that can be built with createAssembledArtifacts.

parseArtifactGenerator :: ArtifactGenerator -> CGParser () Source

Parse an artifacto generator inside a CGParser monad.

withArtifactSources :: [ArtifactSource] -> CGParser () -> CGParser () Source

Execute a CGParser action in an environment that contains a list of ArtifactSources.

data SourceGenerator Source

Internal data type simplifying the rather complex source generation by bioling down ArtifactSources to a flat list of uniform SourceGenerators.

createTarget :: InstanceId -> FilePath -> ArtifactAssembly -> B9 [ArtifactTarget] Source

Create the actual target, either just a mountpoint, or an ISO or VFAT image.