{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.ImageBuilder.Types.ImageRecipe where
import qualified Amazonka.Core as Core
import Amazonka.ImageBuilder.Types.AdditionalInstanceConfiguration
import Amazonka.ImageBuilder.Types.ComponentConfiguration
import Amazonka.ImageBuilder.Types.ImageType
import Amazonka.ImageBuilder.Types.InstanceBlockDeviceMapping
import Amazonka.ImageBuilder.Types.Platform
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data ImageRecipe = ImageRecipe'
{
ImageRecipe -> Maybe (NonEmpty ComponentConfiguration)
components :: Prelude.Maybe (Prelude.NonEmpty ComponentConfiguration),
ImageRecipe -> Maybe Platform
platform :: Prelude.Maybe Platform,
ImageRecipe -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
ImageRecipe -> Maybe AdditionalInstanceConfiguration
additionalInstanceConfiguration :: Prelude.Maybe AdditionalInstanceConfiguration,
ImageRecipe -> Maybe Text
workingDirectory :: Prelude.Maybe Prelude.Text,
ImageRecipe -> Maybe Text
parentImage :: Prelude.Maybe Prelude.Text,
ImageRecipe -> Maybe Text
owner :: Prelude.Maybe Prelude.Text,
ImageRecipe -> Maybe Text
dateCreated :: Prelude.Maybe Prelude.Text,
ImageRecipe -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
ImageRecipe -> Maybe Text
version :: Prelude.Maybe Prelude.Text,
ImageRecipe -> Maybe ImageType
type' :: Prelude.Maybe ImageType,
ImageRecipe -> Maybe [InstanceBlockDeviceMapping]
blockDeviceMappings :: Prelude.Maybe [InstanceBlockDeviceMapping],
ImageRecipe -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
ImageRecipe -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text)
}
deriving (ImageRecipe -> ImageRecipe -> Bool
(ImageRecipe -> ImageRecipe -> Bool)
-> (ImageRecipe -> ImageRecipe -> Bool) -> Eq ImageRecipe
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ImageRecipe -> ImageRecipe -> Bool
$c/= :: ImageRecipe -> ImageRecipe -> Bool
== :: ImageRecipe -> ImageRecipe -> Bool
$c== :: ImageRecipe -> ImageRecipe -> Bool
Prelude.Eq, ReadPrec [ImageRecipe]
ReadPrec ImageRecipe
Int -> ReadS ImageRecipe
ReadS [ImageRecipe]
(Int -> ReadS ImageRecipe)
-> ReadS [ImageRecipe]
-> ReadPrec ImageRecipe
-> ReadPrec [ImageRecipe]
-> Read ImageRecipe
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ImageRecipe]
$creadListPrec :: ReadPrec [ImageRecipe]
readPrec :: ReadPrec ImageRecipe
$creadPrec :: ReadPrec ImageRecipe
readList :: ReadS [ImageRecipe]
$creadList :: ReadS [ImageRecipe]
readsPrec :: Int -> ReadS ImageRecipe
$creadsPrec :: Int -> ReadS ImageRecipe
Prelude.Read, Int -> ImageRecipe -> ShowS
[ImageRecipe] -> ShowS
ImageRecipe -> String
(Int -> ImageRecipe -> ShowS)
-> (ImageRecipe -> String)
-> ([ImageRecipe] -> ShowS)
-> Show ImageRecipe
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ImageRecipe] -> ShowS
$cshowList :: [ImageRecipe] -> ShowS
show :: ImageRecipe -> String
$cshow :: ImageRecipe -> String
showsPrec :: Int -> ImageRecipe -> ShowS
$cshowsPrec :: Int -> ImageRecipe -> ShowS
Prelude.Show, (forall x. ImageRecipe -> Rep ImageRecipe x)
-> (forall x. Rep ImageRecipe x -> ImageRecipe)
-> Generic ImageRecipe
forall x. Rep ImageRecipe x -> ImageRecipe
forall x. ImageRecipe -> Rep ImageRecipe x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ImageRecipe x -> ImageRecipe
$cfrom :: forall x. ImageRecipe -> Rep ImageRecipe x
Prelude.Generic)
newImageRecipe ::
ImageRecipe
newImageRecipe :: ImageRecipe
newImageRecipe =
ImageRecipe' :: Maybe (NonEmpty ComponentConfiguration)
-> Maybe Platform
-> Maybe Text
-> Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe
ImageRecipe'
{ $sel:components:ImageRecipe' :: Maybe (NonEmpty ComponentConfiguration)
components = Maybe (NonEmpty ComponentConfiguration)
forall a. Maybe a
Prelude.Nothing,
$sel:platform:ImageRecipe' :: Maybe Platform
platform = Maybe Platform
forall a. Maybe a
Prelude.Nothing,
$sel:arn:ImageRecipe' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:additionalInstanceConfiguration:ImageRecipe' :: Maybe AdditionalInstanceConfiguration
additionalInstanceConfiguration = Maybe AdditionalInstanceConfiguration
forall a. Maybe a
Prelude.Nothing,
$sel:workingDirectory:ImageRecipe' :: Maybe Text
workingDirectory = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:parentImage:ImageRecipe' :: Maybe Text
parentImage = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:owner:ImageRecipe' :: Maybe Text
owner = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:dateCreated:ImageRecipe' :: Maybe Text
dateCreated = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:name:ImageRecipe' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:version:ImageRecipe' :: Maybe Text
version = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:type':ImageRecipe' :: Maybe ImageType
type' = Maybe ImageType
forall a. Maybe a
Prelude.Nothing,
$sel:blockDeviceMappings:ImageRecipe' :: Maybe [InstanceBlockDeviceMapping]
blockDeviceMappings = Maybe [InstanceBlockDeviceMapping]
forall a. Maybe a
Prelude.Nothing,
$sel:description:ImageRecipe' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:tags:ImageRecipe' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing
}
imageRecipe_components :: Lens.Lens' ImageRecipe (Prelude.Maybe (Prelude.NonEmpty ComponentConfiguration))
imageRecipe_components :: (Maybe (NonEmpty ComponentConfiguration)
-> f (Maybe (NonEmpty ComponentConfiguration)))
-> ImageRecipe -> f ImageRecipe
imageRecipe_components = (ImageRecipe -> Maybe (NonEmpty ComponentConfiguration))
-> (ImageRecipe
-> Maybe (NonEmpty ComponentConfiguration) -> ImageRecipe)
-> Lens
ImageRecipe
ImageRecipe
(Maybe (NonEmpty ComponentConfiguration))
(Maybe (NonEmpty ComponentConfiguration))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe (NonEmpty ComponentConfiguration)
components :: Maybe (NonEmpty ComponentConfiguration)
$sel:components:ImageRecipe' :: ImageRecipe -> Maybe (NonEmpty ComponentConfiguration)
components} -> Maybe (NonEmpty ComponentConfiguration)
components) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe (NonEmpty ComponentConfiguration)
a -> ImageRecipe
s {$sel:components:ImageRecipe' :: Maybe (NonEmpty ComponentConfiguration)
components = Maybe (NonEmpty ComponentConfiguration)
a} :: ImageRecipe) ((Maybe (NonEmpty ComponentConfiguration)
-> f (Maybe (NonEmpty ComponentConfiguration)))
-> ImageRecipe -> f ImageRecipe)
-> ((Maybe (NonEmpty ComponentConfiguration)
-> f (Maybe (NonEmpty ComponentConfiguration)))
-> Maybe (NonEmpty ComponentConfiguration)
-> f (Maybe (NonEmpty ComponentConfiguration)))
-> (Maybe (NonEmpty ComponentConfiguration)
-> f (Maybe (NonEmpty ComponentConfiguration)))
-> ImageRecipe
-> f ImageRecipe
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(NonEmpty ComponentConfiguration)
(NonEmpty ComponentConfiguration)
(NonEmpty ComponentConfiguration)
(NonEmpty ComponentConfiguration)
-> Iso
(Maybe (NonEmpty ComponentConfiguration))
(Maybe (NonEmpty ComponentConfiguration))
(Maybe (NonEmpty ComponentConfiguration))
(Maybe (NonEmpty ComponentConfiguration))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
(NonEmpty ComponentConfiguration)
(NonEmpty ComponentConfiguration)
(NonEmpty ComponentConfiguration)
(NonEmpty ComponentConfiguration)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
imageRecipe_platform :: Lens.Lens' ImageRecipe (Prelude.Maybe Platform)
imageRecipe_platform :: (Maybe Platform -> f (Maybe Platform))
-> ImageRecipe -> f ImageRecipe
imageRecipe_platform = (ImageRecipe -> Maybe Platform)
-> (ImageRecipe -> Maybe Platform -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Platform) (Maybe Platform)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Platform
platform :: Maybe Platform
$sel:platform:ImageRecipe' :: ImageRecipe -> Maybe Platform
platform} -> Maybe Platform
platform) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Platform
a -> ImageRecipe
s {$sel:platform:ImageRecipe' :: Maybe Platform
platform = Maybe Platform
a} :: ImageRecipe)
imageRecipe_arn :: Lens.Lens' ImageRecipe (Prelude.Maybe Prelude.Text)
imageRecipe_arn :: (Maybe Text -> f (Maybe Text)) -> ImageRecipe -> f ImageRecipe
imageRecipe_arn = (ImageRecipe -> Maybe Text)
-> (ImageRecipe -> Maybe Text -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Text
arn :: Maybe Text
$sel:arn:ImageRecipe' :: ImageRecipe -> Maybe Text
arn} -> Maybe Text
arn) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Text
a -> ImageRecipe
s {$sel:arn:ImageRecipe' :: Maybe Text
arn = Maybe Text
a} :: ImageRecipe)
imageRecipe_additionalInstanceConfiguration :: Lens.Lens' ImageRecipe (Prelude.Maybe AdditionalInstanceConfiguration)
imageRecipe_additionalInstanceConfiguration :: (Maybe AdditionalInstanceConfiguration
-> f (Maybe AdditionalInstanceConfiguration))
-> ImageRecipe -> f ImageRecipe
imageRecipe_additionalInstanceConfiguration = (ImageRecipe -> Maybe AdditionalInstanceConfiguration)
-> (ImageRecipe
-> Maybe AdditionalInstanceConfiguration -> ImageRecipe)
-> Lens
ImageRecipe
ImageRecipe
(Maybe AdditionalInstanceConfiguration)
(Maybe AdditionalInstanceConfiguration)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe AdditionalInstanceConfiguration
additionalInstanceConfiguration :: Maybe AdditionalInstanceConfiguration
$sel:additionalInstanceConfiguration:ImageRecipe' :: ImageRecipe -> Maybe AdditionalInstanceConfiguration
additionalInstanceConfiguration} -> Maybe AdditionalInstanceConfiguration
additionalInstanceConfiguration) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe AdditionalInstanceConfiguration
a -> ImageRecipe
s {$sel:additionalInstanceConfiguration:ImageRecipe' :: Maybe AdditionalInstanceConfiguration
additionalInstanceConfiguration = Maybe AdditionalInstanceConfiguration
a} :: ImageRecipe)
imageRecipe_workingDirectory :: Lens.Lens' ImageRecipe (Prelude.Maybe Prelude.Text)
imageRecipe_workingDirectory :: (Maybe Text -> f (Maybe Text)) -> ImageRecipe -> f ImageRecipe
imageRecipe_workingDirectory = (ImageRecipe -> Maybe Text)
-> (ImageRecipe -> Maybe Text -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Text
workingDirectory :: Maybe Text
$sel:workingDirectory:ImageRecipe' :: ImageRecipe -> Maybe Text
workingDirectory} -> Maybe Text
workingDirectory) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Text
a -> ImageRecipe
s {$sel:workingDirectory:ImageRecipe' :: Maybe Text
workingDirectory = Maybe Text
a} :: ImageRecipe)
imageRecipe_parentImage :: Lens.Lens' ImageRecipe (Prelude.Maybe Prelude.Text)
imageRecipe_parentImage :: (Maybe Text -> f (Maybe Text)) -> ImageRecipe -> f ImageRecipe
imageRecipe_parentImage = (ImageRecipe -> Maybe Text)
-> (ImageRecipe -> Maybe Text -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Text
parentImage :: Maybe Text
$sel:parentImage:ImageRecipe' :: ImageRecipe -> Maybe Text
parentImage} -> Maybe Text
parentImage) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Text
a -> ImageRecipe
s {$sel:parentImage:ImageRecipe' :: Maybe Text
parentImage = Maybe Text
a} :: ImageRecipe)
imageRecipe_owner :: Lens.Lens' ImageRecipe (Prelude.Maybe Prelude.Text)
imageRecipe_owner :: (Maybe Text -> f (Maybe Text)) -> ImageRecipe -> f ImageRecipe
imageRecipe_owner = (ImageRecipe -> Maybe Text)
-> (ImageRecipe -> Maybe Text -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Text
owner :: Maybe Text
$sel:owner:ImageRecipe' :: ImageRecipe -> Maybe Text
owner} -> Maybe Text
owner) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Text
a -> ImageRecipe
s {$sel:owner:ImageRecipe' :: Maybe Text
owner = Maybe Text
a} :: ImageRecipe)
imageRecipe_dateCreated :: Lens.Lens' ImageRecipe (Prelude.Maybe Prelude.Text)
imageRecipe_dateCreated :: (Maybe Text -> f (Maybe Text)) -> ImageRecipe -> f ImageRecipe
imageRecipe_dateCreated = (ImageRecipe -> Maybe Text)
-> (ImageRecipe -> Maybe Text -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Text
dateCreated :: Maybe Text
$sel:dateCreated:ImageRecipe' :: ImageRecipe -> Maybe Text
dateCreated} -> Maybe Text
dateCreated) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Text
a -> ImageRecipe
s {$sel:dateCreated:ImageRecipe' :: Maybe Text
dateCreated = Maybe Text
a} :: ImageRecipe)
imageRecipe_name :: Lens.Lens' ImageRecipe (Prelude.Maybe Prelude.Text)
imageRecipe_name :: (Maybe Text -> f (Maybe Text)) -> ImageRecipe -> f ImageRecipe
imageRecipe_name = (ImageRecipe -> Maybe Text)
-> (ImageRecipe -> Maybe Text -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Text
name :: Maybe Text
$sel:name:ImageRecipe' :: ImageRecipe -> Maybe Text
name} -> Maybe Text
name) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Text
a -> ImageRecipe
s {$sel:name:ImageRecipe' :: Maybe Text
name = Maybe Text
a} :: ImageRecipe)
imageRecipe_version :: Lens.Lens' ImageRecipe (Prelude.Maybe Prelude.Text)
imageRecipe_version :: (Maybe Text -> f (Maybe Text)) -> ImageRecipe -> f ImageRecipe
imageRecipe_version = (ImageRecipe -> Maybe Text)
-> (ImageRecipe -> Maybe Text -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Text
version :: Maybe Text
$sel:version:ImageRecipe' :: ImageRecipe -> Maybe Text
version} -> Maybe Text
version) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Text
a -> ImageRecipe
s {$sel:version:ImageRecipe' :: Maybe Text
version = Maybe Text
a} :: ImageRecipe)
imageRecipe_type :: Lens.Lens' ImageRecipe (Prelude.Maybe ImageType)
imageRecipe_type :: (Maybe ImageType -> f (Maybe ImageType))
-> ImageRecipe -> f ImageRecipe
imageRecipe_type = (ImageRecipe -> Maybe ImageType)
-> (ImageRecipe -> Maybe ImageType -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe ImageType) (Maybe ImageType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe ImageType
type' :: Maybe ImageType
$sel:type':ImageRecipe' :: ImageRecipe -> Maybe ImageType
type'} -> Maybe ImageType
type') (\s :: ImageRecipe
s@ImageRecipe' {} Maybe ImageType
a -> ImageRecipe
s {$sel:type':ImageRecipe' :: Maybe ImageType
type' = Maybe ImageType
a} :: ImageRecipe)
imageRecipe_blockDeviceMappings :: Lens.Lens' ImageRecipe (Prelude.Maybe [InstanceBlockDeviceMapping])
imageRecipe_blockDeviceMappings :: (Maybe [InstanceBlockDeviceMapping]
-> f (Maybe [InstanceBlockDeviceMapping]))
-> ImageRecipe -> f ImageRecipe
imageRecipe_blockDeviceMappings = (ImageRecipe -> Maybe [InstanceBlockDeviceMapping])
-> (ImageRecipe
-> Maybe [InstanceBlockDeviceMapping] -> ImageRecipe)
-> Lens
ImageRecipe
ImageRecipe
(Maybe [InstanceBlockDeviceMapping])
(Maybe [InstanceBlockDeviceMapping])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe [InstanceBlockDeviceMapping]
blockDeviceMappings :: Maybe [InstanceBlockDeviceMapping]
$sel:blockDeviceMappings:ImageRecipe' :: ImageRecipe -> Maybe [InstanceBlockDeviceMapping]
blockDeviceMappings} -> Maybe [InstanceBlockDeviceMapping]
blockDeviceMappings) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe [InstanceBlockDeviceMapping]
a -> ImageRecipe
s {$sel:blockDeviceMappings:ImageRecipe' :: Maybe [InstanceBlockDeviceMapping]
blockDeviceMappings = Maybe [InstanceBlockDeviceMapping]
a} :: ImageRecipe) ((Maybe [InstanceBlockDeviceMapping]
-> f (Maybe [InstanceBlockDeviceMapping]))
-> ImageRecipe -> f ImageRecipe)
-> ((Maybe [InstanceBlockDeviceMapping]
-> f (Maybe [InstanceBlockDeviceMapping]))
-> Maybe [InstanceBlockDeviceMapping]
-> f (Maybe [InstanceBlockDeviceMapping]))
-> (Maybe [InstanceBlockDeviceMapping]
-> f (Maybe [InstanceBlockDeviceMapping]))
-> ImageRecipe
-> f ImageRecipe
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[InstanceBlockDeviceMapping]
[InstanceBlockDeviceMapping]
[InstanceBlockDeviceMapping]
[InstanceBlockDeviceMapping]
-> Iso
(Maybe [InstanceBlockDeviceMapping])
(Maybe [InstanceBlockDeviceMapping])
(Maybe [InstanceBlockDeviceMapping])
(Maybe [InstanceBlockDeviceMapping])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
[InstanceBlockDeviceMapping]
[InstanceBlockDeviceMapping]
[InstanceBlockDeviceMapping]
[InstanceBlockDeviceMapping]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
imageRecipe_description :: Lens.Lens' ImageRecipe (Prelude.Maybe Prelude.Text)
imageRecipe_description :: (Maybe Text -> f (Maybe Text)) -> ImageRecipe -> f ImageRecipe
imageRecipe_description = (ImageRecipe -> Maybe Text)
-> (ImageRecipe -> Maybe Text -> ImageRecipe)
-> Lens ImageRecipe ImageRecipe (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe Text
description :: Maybe Text
$sel:description:ImageRecipe' :: ImageRecipe -> Maybe Text
description} -> Maybe Text
description) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe Text
a -> ImageRecipe
s {$sel:description:ImageRecipe' :: Maybe Text
description = Maybe Text
a} :: ImageRecipe)
imageRecipe_tags :: Lens.Lens' ImageRecipe (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
imageRecipe_tags :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> ImageRecipe -> f ImageRecipe
imageRecipe_tags = (ImageRecipe -> Maybe (HashMap Text Text))
-> (ImageRecipe -> Maybe (HashMap Text Text) -> ImageRecipe)
-> Lens
ImageRecipe
ImageRecipe
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImageRecipe' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:ImageRecipe' :: ImageRecipe -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: ImageRecipe
s@ImageRecipe' {} Maybe (HashMap Text Text)
a -> ImageRecipe
s {$sel:tags:ImageRecipe' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: ImageRecipe) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> ImageRecipe -> f ImageRecipe)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> ImageRecipe
-> f ImageRecipe
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance Core.FromJSON ImageRecipe where
parseJSON :: Value -> Parser ImageRecipe
parseJSON =
String
-> (Object -> Parser ImageRecipe) -> Value -> Parser ImageRecipe
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"ImageRecipe"
( \Object
x ->
Maybe (NonEmpty ComponentConfiguration)
-> Maybe Platform
-> Maybe Text
-> Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe
ImageRecipe'
(Maybe (NonEmpty ComponentConfiguration)
-> Maybe Platform
-> Maybe Text
-> Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe (NonEmpty ComponentConfiguration))
-> Parser
(Maybe Platform
-> Maybe Text
-> Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe (NonEmpty ComponentConfiguration))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"components")
Parser
(Maybe Platform
-> Maybe Text
-> Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe Platform)
-> Parser
(Maybe Text
-> Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Platform)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"platform")
Parser
(Maybe Text
-> Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe Text)
-> Parser
(Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"arn")
Parser
(Maybe AdditionalInstanceConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe AdditionalInstanceConfiguration)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe AdditionalInstanceConfiguration)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"additionalInstanceConfiguration")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"workingDirectory")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"parentImage")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"owner")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"dateCreated")
Parser
(Maybe Text
-> Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"name")
Parser
(Maybe Text
-> Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe Text)
-> Parser
(Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"version")
Parser
(Maybe ImageType
-> Maybe [InstanceBlockDeviceMapping]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> ImageRecipe)
-> Parser (Maybe ImageType)
-> Parser
(Maybe [InstanceBlockDeviceMapping]
-> Maybe Text -> Maybe (HashMap Text Text) -> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ImageType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"type")
Parser
(Maybe [InstanceBlockDeviceMapping]
-> Maybe Text -> Maybe (HashMap Text Text) -> ImageRecipe)
-> Parser (Maybe [InstanceBlockDeviceMapping])
-> Parser (Maybe Text -> Maybe (HashMap Text Text) -> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text -> Parser (Maybe (Maybe [InstanceBlockDeviceMapping]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"blockDeviceMappings"
Parser (Maybe (Maybe [InstanceBlockDeviceMapping]))
-> Maybe [InstanceBlockDeviceMapping]
-> Parser (Maybe [InstanceBlockDeviceMapping])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [InstanceBlockDeviceMapping]
forall a. Monoid a => a
Prelude.mempty
)
Parser (Maybe Text -> Maybe (HashMap Text Text) -> ImageRecipe)
-> Parser (Maybe Text)
-> Parser (Maybe (HashMap Text Text) -> ImageRecipe)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"description")
Parser (Maybe (HashMap Text Text) -> ImageRecipe)
-> Parser (Maybe (HashMap Text Text)) -> Parser ImageRecipe
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"tags" Parser (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> Parser (Maybe (HashMap Text Text))
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty)
)
instance Prelude.Hashable ImageRecipe
instance Prelude.NFData ImageRecipe