-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Dockerfile parser, pretty-printer and embedded DSL
--   
--   All functions for parsing, printing and writting Dockerfiles are
--   exported through <tt>Language.Docker</tt>. For more fine-grained
--   operations look for specific modules that implement a certain
--   functionality. See the <a>GitHub project</a> for the source-code and
--   examples.
@package language-docker
@version 2.0.1

module Language.Docker.Lexer
reserved :: String -> Parser ()
natural :: Parser Integer
commaSep :: Parser a -> Parser [a]
stringLiteral :: Parser String
brackets :: Parser a -> Parser a
whiteSpace :: Parser ()
space :: Parser ()
spaces1 :: Parser ()
spaces :: Parser ()
symbol :: String -> Parser String
caseInsensitiveChar :: Char -> Parser Char
caseInsensitiveString :: String -> Parser String
charsWithEscapedSpaces :: String -> Parser String
lexeme :: Parser a -> Parser a

module Language.Docker.Normalize

-- | Remove new line escapes and join escaped lines together on one line to
--   simplify parsing later on. Escapes are replaced with line breaks to
--   not alter the line numbers.
normalizeEscapedLines :: String -> String

module Language.Docker.Syntax
type Image = String
type Tag = String
data Protocol
TCP :: Protocol
UDP :: Protocol
data Port
Port :: Integer -> Protocol -> Port
PortStr :: String -> Port
PortRange :: Integer -> Integer -> Port
newtype Ports
Ports :: [Port] -> Ports
[$sel:unPorts:Ports] :: Ports -> [Port]
type Directory = String
newtype ImageAlias
ImageAlias :: String -> ImageAlias
[$sel:unImageAlias:ImageAlias] :: ImageAlias -> String
data BaseImage
UntaggedImage :: Image -> (Maybe ImageAlias) -> BaseImage
TaggedImage :: Image -> Tag -> (Maybe ImageAlias) -> BaseImage
DigestedImage :: Image -> ByteString -> (Maybe ImageAlias) -> BaseImage

-- | Type of the Dockerfile AST
type Dockerfile = [InstructionPos]
newtype SourcePath
SourcePath :: String -> SourcePath
[$sel:unSourcePath:SourcePath] :: SourcePath -> String
newtype TargetPath
TargetPath :: String -> TargetPath
[$sel:unTargetPath:TargetPath] :: TargetPath -> String
data Chown
Chown :: String -> Chown
NoChown :: Chown
data CopySource
CopySource :: String -> CopySource
NoSource :: CopySource
newtype Duration
Duration :: DiffTime -> Duration
[$sel:durationTime:Duration] :: Duration -> DiffTime
newtype Retries
Retries :: Int -> Retries
[$sel:times:Retries] :: Retries -> Int
data CopyArgs
CopyArgs :: NonEmpty SourcePath -> TargetPath -> Chown -> CopySource -> CopyArgs
[$sel:sourcePaths:CopyArgs] :: CopyArgs -> NonEmpty SourcePath
[$sel:targetPath:CopyArgs] :: CopyArgs -> TargetPath
[$sel:chownFlag:CopyArgs] :: CopyArgs -> Chown
[$sel:sourceFlag:CopyArgs] :: CopyArgs -> CopySource
data AddArgs
AddArgs :: NonEmpty SourcePath -> TargetPath -> Chown -> AddArgs
[$sel:sourcePaths:AddArgs] :: AddArgs -> NonEmpty SourcePath
[$sel:targetPath:AddArgs] :: AddArgs -> TargetPath
[$sel:chownFlag:AddArgs] :: AddArgs -> Chown
data Check
Check :: CheckArgs -> Check
NoCheck :: Check
data CheckArgs
CheckArgs :: Arguments -> Maybe Duration -> Maybe Duration -> Maybe Duration -> Maybe Retries -> CheckArgs
[$sel:checkCommand:CheckArgs] :: CheckArgs -> Arguments
[$sel:interval:CheckArgs] :: CheckArgs -> Maybe Duration
[$sel:timeout:CheckArgs] :: CheckArgs -> Maybe Duration
[$sel:startPeriod:CheckArgs] :: CheckArgs -> Maybe Duration
[$sel:retries:CheckArgs] :: CheckArgs -> Maybe Retries
type Arguments = [String]
type Pairs = [(String, String)]

-- | All commands available in Dockerfiles
data Instruction
From :: BaseImage -> Instruction
Add :: AddArgs -> Instruction
User :: String -> Instruction
Label :: Pairs -> Instruction
Stopsignal :: String -> Instruction
Copy :: CopyArgs -> Instruction
Run :: Arguments -> Instruction
Cmd :: Arguments -> Instruction
Shell :: Arguments -> Instruction
Workdir :: Directory -> Instruction
Expose :: Ports -> Instruction
Volume :: String -> Instruction
Entrypoint :: Arguments -> Instruction
Maintainer :: String -> Instruction
Env :: Pairs -> Instruction
Arg :: String -> (Maybe String) -> Instruction
Healthcheck :: Check -> Instruction
Comment :: String -> Instruction
OnBuild :: Instruction -> Instruction
type Filename = String
type Linenumber = Int

-- | <a>Instruction</a> with additional location information required for
--   creating good check messages
data InstructionPos
InstructionPos :: Instruction -> Filename -> Linenumber -> InstructionPos
[$sel:instruction:InstructionPos] :: InstructionPos -> Instruction
[$sel:sourcename:InstructionPos] :: InstructionPos -> Filename
[$sel:lineNumber:InstructionPos] :: InstructionPos -> Linenumber
instance GHC.Show.Show Language.Docker.Syntax.InstructionPos
instance GHC.Classes.Ord Language.Docker.Syntax.InstructionPos
instance GHC.Classes.Eq Language.Docker.Syntax.InstructionPos
instance GHC.Show.Show Language.Docker.Syntax.Instruction
instance GHC.Classes.Ord Language.Docker.Syntax.Instruction
instance GHC.Classes.Eq Language.Docker.Syntax.Instruction
instance GHC.Classes.Ord Language.Docker.Syntax.Check
instance GHC.Classes.Eq Language.Docker.Syntax.Check
instance GHC.Show.Show Language.Docker.Syntax.Check
instance GHC.Classes.Ord Language.Docker.Syntax.CheckArgs
instance GHC.Classes.Eq Language.Docker.Syntax.CheckArgs
instance GHC.Show.Show Language.Docker.Syntax.CheckArgs
instance GHC.Classes.Ord Language.Docker.Syntax.AddArgs
instance GHC.Classes.Eq Language.Docker.Syntax.AddArgs
instance GHC.Show.Show Language.Docker.Syntax.AddArgs
instance GHC.Classes.Ord Language.Docker.Syntax.CopyArgs
instance GHC.Classes.Eq Language.Docker.Syntax.CopyArgs
instance GHC.Show.Show Language.Docker.Syntax.CopyArgs
instance GHC.Num.Num Language.Docker.Syntax.Retries
instance GHC.Classes.Ord Language.Docker.Syntax.Retries
instance GHC.Classes.Eq Language.Docker.Syntax.Retries
instance GHC.Show.Show Language.Docker.Syntax.Retries
instance GHC.Num.Num Language.Docker.Syntax.Duration
instance GHC.Classes.Ord Language.Docker.Syntax.Duration
instance GHC.Classes.Eq Language.Docker.Syntax.Duration
instance GHC.Show.Show Language.Docker.Syntax.Duration
instance GHC.Classes.Ord Language.Docker.Syntax.CopySource
instance GHC.Classes.Eq Language.Docker.Syntax.CopySource
instance GHC.Show.Show Language.Docker.Syntax.CopySource
instance GHC.Classes.Ord Language.Docker.Syntax.Chown
instance GHC.Classes.Eq Language.Docker.Syntax.Chown
instance GHC.Show.Show Language.Docker.Syntax.Chown
instance Data.String.IsString Language.Docker.Syntax.TargetPath
instance GHC.Classes.Ord Language.Docker.Syntax.TargetPath
instance GHC.Classes.Eq Language.Docker.Syntax.TargetPath
instance GHC.Show.Show Language.Docker.Syntax.TargetPath
instance Data.String.IsString Language.Docker.Syntax.SourcePath
instance GHC.Classes.Ord Language.Docker.Syntax.SourcePath
instance GHC.Classes.Eq Language.Docker.Syntax.SourcePath
instance GHC.Show.Show Language.Docker.Syntax.SourcePath
instance GHC.Show.Show Language.Docker.Syntax.BaseImage
instance GHC.Classes.Ord Language.Docker.Syntax.BaseImage
instance GHC.Classes.Eq Language.Docker.Syntax.BaseImage
instance Data.String.IsString Language.Docker.Syntax.ImageAlias
instance GHC.Classes.Ord Language.Docker.Syntax.ImageAlias
instance GHC.Classes.Eq Language.Docker.Syntax.ImageAlias
instance GHC.Show.Show Language.Docker.Syntax.ImageAlias
instance GHC.Classes.Ord Language.Docker.Syntax.Ports
instance GHC.Classes.Eq Language.Docker.Syntax.Ports
instance GHC.Show.Show Language.Docker.Syntax.Ports
instance GHC.Classes.Ord Language.Docker.Syntax.Port
instance GHC.Classes.Eq Language.Docker.Syntax.Port
instance GHC.Show.Show Language.Docker.Syntax.Port
instance GHC.Classes.Ord Language.Docker.Syntax.Protocol
instance GHC.Classes.Eq Language.Docker.Syntax.Protocol
instance GHC.Show.Show Language.Docker.Syntax.Protocol
instance GHC.Exts.IsList Language.Docker.Syntax.Ports

module Language.Docker.PrettyPrint

-- | Pretty print a <a>Dockerfile</a> to a <a>String</a>
prettyPrint :: Dockerfile -> String

-- | Pretty print a <a>InstructionPos</a> to a <a>String</a>
prettyPrintInstructionPos :: InstructionPos -> String
prettyPrintBaseImage :: BaseImage -> Doc
prettyPrintPairs :: Pairs -> Doc
prettyPrintPair :: (String, String) -> Doc
prettyPrintArguments :: Arguments -> Doc
prettyPrintJSON :: Arguments -> Doc
prettyPrintPort :: Port -> Doc
prettyPrintFileList :: NonEmpty SourcePath -> TargetPath -> Doc
prettyPrintChown :: Chown -> Doc
prettyPrintCopySource :: CopySource -> Doc
prettyPrintDuration :: String -> Maybe Duration -> Doc
prettyPrintRetries :: Maybe Retries -> Doc
prettyPrintInstruction :: Instruction -> Doc

module Language.Docker.Parser
data CopyFlag
FlagChown :: Chown -> CopyFlag
FlagSource :: CopySource -> CopyFlag
FlagInvalid :: (String, String) -> CopyFlag
data CheckFlag
FlagInterval :: Duration -> CheckFlag
FlagTimeout :: Duration -> CheckFlag
FlagStartPeriod :: Duration -> CheckFlag
FlagRetries :: Retries -> CheckFlag
CFlagInvalid :: (String, String) -> CheckFlag
comment :: Parser Instruction
taggedImage :: Parser BaseImage
digestedImage :: Parser BaseImage
untaggedImage :: Parser BaseImage
maybeImageAlias :: Parser (Maybe ImageAlias)
imageAlias :: Parser ImageAlias
baseImage :: Parser BaseImage
from :: Parser Instruction
cmd :: Parser Instruction
copy :: Parser Instruction
copyFlag :: Parser CopyFlag
chown :: Parser Chown
copySource :: Parser CopySource
anyFlag :: Parser (String, String)
fileList :: String -> (NonEmpty SourcePath -> TargetPath -> Instruction) -> Parser Instruction
unexpectedFlag :: String -> String -> Parser a
shell :: Parser Instruction
stopsignal :: Parser Instruction
doubleQuotedValue :: Parser String
singleQuotedValue :: Parser String
unquotedString :: String -> Parser String
singleValue :: String -> Parser String
pair :: Parser (String, String)
pairsList :: Parser Pairs
label :: Parser Instruction
arg :: Parser Instruction
env :: Parser Instruction
pairs :: Parser Pairs
singlePair :: Parser Pairs
user :: Parser Instruction
add :: Parser Instruction
expose :: Parser Instruction
port :: Parser Port
ports :: Parser Ports
portRange :: Parser Port
portInt :: Parser Port
portWithProtocol :: Parser Port
portVariable :: Parser Port
run :: Parser Instruction
untilEol :: Parser String
untilOccurrence :: String -> Parser String
workdir :: Parser Instruction
volume :: Parser Instruction
maintainer :: Parser Instruction
argumentsExec :: Parser Arguments
argumentsShell :: Parser Arguments
arguments :: Parser Arguments
entrypoint :: Parser Instruction
onbuild :: Parser Instruction
healthcheck :: Parser Instruction
checkFlag :: Parser CheckFlag
durationFlag :: String -> Parser Duration
retriesFlag :: Parser Retries
parseInstruction :: Parser Instruction
contents :: Parser a -> Parser a
eol :: Parser ()
dockerfile :: Parser Dockerfile
parseString :: String -> Either ParseError Dockerfile
parseFile :: String -> IO (Either ParseError Dockerfile)

module Language.Docker.EDSL.Types
data EBaseImage
EUntaggedImage :: String -> (Maybe ImageAlias) -> EBaseImage
ETaggedImage :: String -> String -> (Maybe ImageAlias) -> EBaseImage
EDigestedImage :: String -> ByteString -> (Maybe ImageAlias) -> EBaseImage
data EInstruction next
From :: EBaseImage -> next -> EInstruction next
AddArgs :: (NonEmpty SourcePath) -> TargetPath -> Chown -> next -> EInstruction next
User :: String -> next -> EInstruction next
Label :: Pairs -> next -> EInstruction next
StopSignal :: String -> next -> EInstruction next
CopyArgs :: (NonEmpty SourcePath) -> TargetPath -> Chown -> CopySource -> next -> EInstruction next
RunArgs :: Arguments -> next -> EInstruction next
CmdArgs :: Arguments -> next -> EInstruction next
Shell :: Arguments -> next -> EInstruction next
Workdir :: Directory -> next -> EInstruction next
Expose :: Ports -> next -> EInstruction next
Volume :: String -> next -> EInstruction next
EntrypointArgs :: Arguments -> next -> EInstruction next
Maintainer :: String -> next -> EInstruction next
Env :: Pairs -> next -> EInstruction next
Arg :: String -> (Maybe String) -> next -> EInstruction next
Comment :: String -> next -> EInstruction next
Healthcheck :: Check -> next -> EInstruction next
OnBuildRaw :: Instruction -> next -> EInstruction next
Embed :: [InstructionPos] -> next -> EInstruction next
instance GHC.Base.Functor Language.Docker.EDSL.Types.EInstruction
instance GHC.Classes.Ord Language.Docker.EDSL.Types.EBaseImage
instance GHC.Classes.Eq Language.Docker.EDSL.Types.EBaseImage
instance GHC.Show.Show Language.Docker.EDSL.Types.EBaseImage
instance Data.String.IsString Language.Docker.EDSL.Types.EBaseImage

module Language.Docker.EDSL

-- | The type of <tt>Identity</tt> based EDSL blocks
type EDockerfileM = Free EInstruction

-- | The type of free monad EDSL blocks
type EDockerfileTM = FreeT EInstruction
type EInstructionM = Free EInstruction
type EInstructionTM = FreeT EInstruction
embed :: forall m_aELf. MonadFree EInstruction m_aELf => [InstructionPos] -> m_aELf ()
onBuildRaw :: forall m_aELc. MonadFree EInstruction m_aELc => Instruction -> m_aELc ()
healthcheck :: forall m_aEL9. MonadFree EInstruction m_aEL9 => Check -> m_aEL9 ()
comment :: forall m_aEL6. MonadFree EInstruction m_aEL6 => String -> m_aEL6 ()
arg :: forall m_aEL2. MonadFree EInstruction m_aEL2 => String -> Maybe String -> m_aEL2 ()
env :: forall m_aEKZ. MonadFree EInstruction m_aEKZ => Pairs -> m_aEKZ ()
maintainer :: forall m_aEKW. MonadFree EInstruction m_aEKW => String -> m_aEKW ()
entrypointArgs :: forall m_aEKT. MonadFree EInstruction m_aEKT => Arguments -> m_aEKT ()
volume :: forall m_aEKQ. MonadFree EInstruction m_aEKQ => String -> m_aEKQ ()
expose :: forall m_aEKN. MonadFree EInstruction m_aEKN => Ports -> m_aEKN ()
workdir :: forall m_aEKK. MonadFree EInstruction m_aEKK => Directory -> m_aEKK ()
shell :: forall m_aEKH. MonadFree EInstruction m_aEKH => Arguments -> m_aEKH ()
cmdArgs :: forall m_aEKE. MonadFree EInstruction m_aEKE => Arguments -> m_aEKE ()
runArgs :: forall m_aEKB. MonadFree EInstruction m_aEKB => Arguments -> m_aEKB ()
copyArgs :: forall m_aEKv. MonadFree EInstruction m_aEKv => NonEmpty SourcePath -> TargetPath -> Chown -> CopySource -> m_aEKv ()
stopSignal :: forall m_aEKs. MonadFree EInstruction m_aEKs => String -> m_aEKs ()
label :: forall m_aEKp. MonadFree EInstruction m_aEKp => Pairs -> m_aEKp ()
user :: forall m_aEKm. MonadFree EInstruction m_aEKm => String -> m_aEKm ()
addArgs :: forall m_aEKh. MonadFree EInstruction m_aEKh => NonEmpty SourcePath -> TargetPath -> Chown -> m_aEKh ()
from :: forall m_aEIj. MonadFree EInstruction m_aEIj => EBaseImage -> m_aEIj ()
runDockerWriter :: (MonadWriter [Instruction] m) => EDockerfileM a -> m a
runDockerWriterIO :: (Monad m, MonadTrans t, Monad (t m), MonadWriter [Instruction] (t m), MonadIO (t m)) => EDockerfileTM m a -> t m a
runDef :: MonadWriter [t] m => (t1 -> t) -> t1 -> m b -> m b
runDef2 :: MonadWriter [t] m => (t1 -> t2 -> t) -> t1 -> t2 -> m b -> m b
runD :: MonadWriter [Instruction] m => EInstruction (m b) -> m b
instructionPos :: Instruction -> InstructionPos

-- | Runs the Dockerfile EDSL and returns a <tt>Dockerfile</tt> you can
--   pretty print or manipulate
toDockerfile :: EDockerfileM a -> Dockerfile

-- | runs the Dockerfile EDSL and returns a <a>String</a> using
--   <a>PrettyPrint</a>
--   
--   <pre>
--   import           Language.Docker
--   
--   main :: IO ()
--   main = writeFile "something.dockerfile" $ toDockerfileStr $ do
--       from (tagged "fpco/stack-build" "lts-6.9")
--       add ["."] "<i>app</i>language-docker"
--       workdir "<i>app</i>language-docker"
--       run (words "stack build --test --only-dependencies")
--       cmd (words "stack test")
--   </pre>
toDockerfileStr :: EDockerfileM a -> String
untagged :: String -> EBaseImage
tagged :: String -> String -> EBaseImage
digested :: String -> ByteString -> EBaseImage
aliased :: EBaseImage -> String -> EBaseImage
ports :: [Port] -> Ports
tcpPort :: Integer -> Port
udpPort :: Integer -> Port
variablePort :: String -> Port
portRange :: Integer -> Integer -> Port
run :: MonadFree EInstruction m => String -> m ()
entrypoint :: MonadFree EInstruction m => String -> m ()
cmd :: MonadFree EInstruction m => String -> m ()
copy :: MonadFree EInstruction m => NonEmpty SourcePath -> TargetPath -> m ()
add :: MonadFree EInstruction m => NonEmpty SourcePath -> TargetPath -> m ()
check :: String -> Check
interval :: Check -> Integer -> Check
timeout :: Check -> Integer -> Check
startPeriod :: Check -> Integer -> Check
retries :: Check -> Integer -> Check
noCheck :: Check

-- | ONBUILD Dockerfile instruction
--   
--   Each nested instruction gets emitted as a separate <tt>ONBUILD</tt>
--   block
--   
--   <pre>
--   <a>toDockerfile</a> $ do
--       from "node"
--       run "apt-get update"
--       onBuild $ do
--           run "echo more-stuff"
--           run "echo here"
--   </pre>
onBuild :: MonadFree EInstruction m => EDockerfileM a -> m ()

-- | A version of <a>toDockerfile</a> which allows IO actions
toDockerfileIO :: MonadIO m => EDockerfileTM m t -> m Dockerfile

-- | A version of <a>toDockerfileStr</a> which allows IO actions
toDockerfileStrIO :: MonadIO m => EDockerfileTM m t -> m String

-- | Just runs the EDSL's writer monad
runDockerfileIO :: MonadIO m => EDockerfileTM m t -> m (t, Dockerfile)

-- | Runs the EDSL's writer monad and pretty-prints the result
runDockerfileStrIO :: MonadIO m => EDockerfileTM m t -> m (t, String)

module Language.Docker.Syntax.Lift
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.Check
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.CheckArgs
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.Retries
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.Duration
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.AddArgs
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.CopyArgs
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.CopySource
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.Chown
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.TargetPath
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.SourcePath
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.InstructionPos
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.Instruction
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.BaseImage
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.ImageAlias
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.Ports
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.Port
instance Language.Haskell.TH.Syntax.Lift Language.Docker.Syntax.Protocol
instance Language.Haskell.TH.Syntax.Lift Data.Time.Clock.Internal.DiffTime.DiffTime
instance Language.Haskell.TH.Syntax.Lift (Data.Fixed.Fixed a)
instance Language.Haskell.TH.Syntax.Lift a => Language.Haskell.TH.Syntax.Lift (Data.List.NonEmpty.NonEmpty a)

module Language.Docker.EDSL.Quasi

-- | Quasiquoter for embedding dockerfiles on the EDSL
--   
--   <pre>
--   putStr $ <a>toDockerfile</a> $ do
--       from "node"
--       run "apt-get update"
--       [edockerfile|
--       RUN apt-get update
--       CMD node something.js
--       |]
--   </pre>
edockerfile :: QuasiQuoter
edockerfileE :: String -> ExpQ
dockerfile :: QuasiQuoter
dockerfileE :: String -> ExpQ

module Language.Docker

-- | Type of the Dockerfile AST
type Dockerfile = [InstructionPos]
parseString :: String -> Either ParseError Dockerfile
parseFile :: String -> IO (Either ParseError Dockerfile)

-- | Pretty print a <a>Dockerfile</a> to a <a>String</a>
prettyPrint :: Dockerfile -> String

-- | Pretty print a <a>InstructionPos</a> to a <a>String</a>
prettyPrintInstructionPos :: InstructionPos -> String

-- | runs the Dockerfile EDSL and returns a <a>String</a> using
--   <a>PrettyPrint</a>
--   
--   <pre>
--   import           Language.Docker
--   
--   main :: IO ()
--   main = writeFile "something.dockerfile" $ toDockerfileStr $ do
--       from (tagged "fpco/stack-build" "lts-6.9")
--       add ["."] "<i>app</i>language-docker"
--       workdir "<i>app</i>language-docker"
--       run (words "stack build --test --only-dependencies")
--       cmd (words "stack test")
--   </pre>
toDockerfileStr :: EDockerfileM a -> String

-- | Runs the Dockerfile EDSL and returns a <tt>Dockerfile</tt> you can
--   pretty print or manipulate
toDockerfile :: EDockerfileM a -> Dockerfile

-- | A version of <a>toDockerfileStr</a> which allows IO actions
toDockerfileStrIO :: MonadIO m => EDockerfileTM m t -> m String

-- | A version of <a>toDockerfile</a> which allows IO actions
toDockerfileIO :: MonadIO m => EDockerfileTM m t -> m Dockerfile

-- | Just runs the EDSL's writer monad
runDockerfileIO :: MonadIO m => EDockerfileTM m t -> m (t, Dockerfile)

-- | Runs the EDSL's writer monad and pretty-prints the result
runDockerfileStrIO :: MonadIO m => EDockerfileTM m t -> m (t, String)

-- | Lift a computation from the <a>IO</a> monad.
liftIO :: MonadIO m => forall a. () => IO a -> m a
from :: forall m_aEIj. MonadFree EInstruction m_aEIj => EBaseImage -> m_aEIj ()
tagged :: String -> String -> EBaseImage
untagged :: String -> EBaseImage
digested :: String -> ByteString -> EBaseImage
aliased :: EBaseImage -> String -> EBaseImage
add :: MonadFree EInstruction m => NonEmpty SourcePath -> TargetPath -> m ()
user :: forall m_aEKm. MonadFree EInstruction m_aEKm => String -> m_aEKm ()
label :: forall m_aEKp. MonadFree EInstruction m_aEKp => Pairs -> m_aEKp ()
stopSignal :: forall m_aEKs. MonadFree EInstruction m_aEKs => String -> m_aEKs ()
copy :: MonadFree EInstruction m => NonEmpty SourcePath -> TargetPath -> m ()
run :: MonadFree EInstruction m => String -> m ()
runArgs :: forall m_aEKB. MonadFree EInstruction m_aEKB => Arguments -> m_aEKB ()
cmd :: MonadFree EInstruction m => String -> m ()
cmdArgs :: forall m_aEKE. MonadFree EInstruction m_aEKE => Arguments -> m_aEKE ()
healthcheck :: forall m_aEL9. MonadFree EInstruction m_aEL9 => Check -> m_aEL9 ()
check :: String -> Check
interval :: Check -> Integer -> Check
timeout :: Check -> Integer -> Check
startPeriod :: Check -> Integer -> Check
retries :: Check -> Integer -> Check
workdir :: forall m_aEKK. MonadFree EInstruction m_aEKK => Directory -> m_aEKK ()
expose :: forall m_aEKN. MonadFree EInstruction m_aEKN => Ports -> m_aEKN ()
ports :: [Port] -> Ports
tcpPort :: Integer -> Port
udpPort :: Integer -> Port
variablePort :: String -> Port
volume :: forall m_aEKQ. MonadFree EInstruction m_aEKQ => String -> m_aEKQ ()
entrypoint :: MonadFree EInstruction m => String -> m ()
entrypointArgs :: forall m_aEKT. MonadFree EInstruction m_aEKT => Arguments -> m_aEKT ()
maintainer :: forall m_aEKW. MonadFree EInstruction m_aEKW => String -> m_aEKW ()
env :: forall m_aEKZ. MonadFree EInstruction m_aEKZ => Pairs -> m_aEKZ ()
arg :: forall m_aEL2. MonadFree EInstruction m_aEL2 => String -> Maybe String -> m_aEL2 ()
comment :: forall m_aEL6. MonadFree EInstruction m_aEL6 => String -> m_aEL6 ()

-- | ONBUILD Dockerfile instruction
--   
--   Each nested instruction gets emitted as a separate <tt>ONBUILD</tt>
--   block
--   
--   <pre>
--   <a>toDockerfile</a> $ do
--       from "node"
--       run "apt-get update"
--       onBuild $ do
--           run "echo more-stuff"
--           run "echo here"
--   </pre>
onBuild :: MonadFree EInstruction m => EDockerfileM a -> m ()
onBuildRaw :: forall m_aELc. MonadFree EInstruction m_aELc => Instruction -> m_aELc ()
embed :: forall m_aELf. MonadFree EInstruction m_aELf => [InstructionPos] -> m_aELf ()

-- | Quasiquoter for embedding dockerfiles on the EDSL
--   
--   <pre>
--   putStr $ <a>toDockerfile</a> $ do
--       from "node"
--       run "apt-get update"
--       [edockerfile|
--       RUN apt-get update
--       CMD node something.js
--       |]
--   </pre>
edockerfile :: QuasiQuoter

-- | The type of <tt>Identity</tt> based EDSL blocks
type EDockerfileM = Free EInstruction

-- | The type of free monad EDSL blocks
type EDockerfileTM = FreeT EInstruction
data EBaseImage
EUntaggedImage :: String -> (Maybe ImageAlias) -> EBaseImage
ETaggedImage :: String -> String -> (Maybe ImageAlias) -> EBaseImage
EDigestedImage :: String -> ByteString -> (Maybe ImageAlias) -> EBaseImage
dockerfile :: QuasiQuoter

-- | All commands available in Dockerfiles
data Instruction
From :: BaseImage -> Instruction
Add :: AddArgs -> Instruction
User :: String -> Instruction
Label :: Pairs -> Instruction
Stopsignal :: String -> Instruction
Copy :: CopyArgs -> Instruction
Run :: Arguments -> Instruction
Cmd :: Arguments -> Instruction
Shell :: Arguments -> Instruction
Workdir :: Directory -> Instruction
Expose :: Ports -> Instruction
Volume :: String -> Instruction
Entrypoint :: Arguments -> Instruction
Maintainer :: String -> Instruction
Env :: Pairs -> Instruction
Arg :: String -> (Maybe String) -> Instruction
Healthcheck :: Check -> Instruction
Comment :: String -> Instruction
OnBuild :: Instruction -> Instruction

-- | <a>Instruction</a> with additional location information required for
--   creating good check messages
data InstructionPos
InstructionPos :: Instruction -> Filename -> Linenumber -> InstructionPos
[$sel:instruction:InstructionPos] :: InstructionPos -> Instruction
[$sel:sourcename:InstructionPos] :: InstructionPos -> Filename
[$sel:lineNumber:InstructionPos] :: InstructionPos -> Linenumber
data BaseImage
UntaggedImage :: Image -> (Maybe ImageAlias) -> BaseImage
TaggedImage :: Image -> Tag -> (Maybe ImageAlias) -> BaseImage
DigestedImage :: Image -> ByteString -> (Maybe ImageAlias) -> BaseImage
newtype SourcePath
SourcePath :: String -> SourcePath
[$sel:unSourcePath:SourcePath] :: SourcePath -> String
newtype TargetPath
TargetPath :: String -> TargetPath
[$sel:unTargetPath:TargetPath] :: TargetPath -> String
data Chown
Chown :: String -> Chown
NoChown :: Chown
data CopySource
CopySource :: String -> CopySource
NoSource :: CopySource
data CopyArgs
CopyArgs :: NonEmpty SourcePath -> TargetPath -> Chown -> CopySource -> CopyArgs
[$sel:sourcePaths:CopyArgs] :: CopyArgs -> NonEmpty SourcePath
[$sel:targetPath:CopyArgs] :: CopyArgs -> TargetPath
[$sel:chownFlag:CopyArgs] :: CopyArgs -> Chown
[$sel:sourceFlag:CopyArgs] :: CopyArgs -> CopySource
data AddArgs
AddArgs :: NonEmpty SourcePath -> TargetPath -> Chown -> AddArgs
[$sel:sourcePaths:AddArgs] :: AddArgs -> NonEmpty SourcePath
[$sel:targetPath:AddArgs] :: AddArgs -> TargetPath
[$sel:chownFlag:AddArgs] :: AddArgs -> Chown
data Check
Check :: CheckArgs -> Check
NoCheck :: Check
data CheckArgs
CheckArgs :: Arguments -> Maybe Duration -> Maybe Duration -> Maybe Duration -> Maybe Retries -> CheckArgs
[$sel:checkCommand:CheckArgs] :: CheckArgs -> Arguments
[$sel:interval:CheckArgs] :: CheckArgs -> Maybe Duration
[$sel:timeout:CheckArgs] :: CheckArgs -> Maybe Duration
[$sel:startPeriod:CheckArgs] :: CheckArgs -> Maybe Duration
[$sel:retries:CheckArgs] :: CheckArgs -> Maybe Retries
type Image = String
newtype ImageAlias
ImageAlias :: String -> ImageAlias
[$sel:unImageAlias:ImageAlias] :: ImageAlias -> String
type Tag = String
data Ports
type Directory = String
type Arguments = [String]
type Pairs = [(String, String)]
type Filename = String
type Linenumber = Int

-- | The abstract data type <tt>ParseError</tt> represents parse errors. It
--   provides the source position (<a>SourcePos</a>) of the error and a
--   list of error messages (<a>Message</a>). A <tt>ParseError</tt> can be
--   returned by the function <a>parse</a>. <tt>ParseError</tt> is an
--   instance of the <a>Show</a> and <a>Eq</a> classes.
data ParseError :: *
instructionPos :: Instruction -> InstructionPos

module Language.Docker.Predef
appendLnIfMissing :: FilePath -> Text -> IO ()
dockerIgnore :: Text -> IO ()
addGlob :: (MonadIO m, MonadFree EInstruction m) => String -> TargetPath -> m ()
copyGlob :: (MonadIO m, MonadFree EInstruction m) => String -> TargetPath -> m ()
stackBuild :: (Monad m, MonadIO m, MonadFree EInstruction m) => m ()
stackBuild' :: (Monad m, MonadIO m, MonadFree EInstruction m) => String -> m () -> m ()
nodejs :: (Monad m, MonadIO m, MonadFree EInstruction m) => m ()
nodejs' :: (Monad m, MonadIO m, MonadFree EInstruction m) => String -> m () -> m ()
