{-# 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 #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.SecurityHub.Types.AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.SecurityHub.Types.AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SecurityHub.Types.AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails

-- | Information about the Amazon Elastic File System file system that is
-- used for task storage.
--
-- /See:/ 'newAwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' smart constructor.
data AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails = AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails'
  { -- | The directory within the Amazon EFS file system to mount as the root
    -- directory inside the host.
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
rootDirectory :: Prelude.Maybe Prelude.Text,
    -- | Whether to enable encryption for Amazon EFS data in transit between the
    -- Amazon ECS host and the Amazon EFS server.
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
transitEncryption :: Prelude.Maybe Prelude.Text,
    -- | The Amazon EFS file system identifier to use.
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
filesystemId :: Prelude.Maybe Prelude.Text,
    -- | The authorization configuration details for the Amazon EFS file system.
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
authorizationConfig :: Prelude.Maybe AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails,
    -- | The port to use when sending encrypted data between the Amazon ECS host
    -- and the Amazon EFS server.
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Int
transitEncryptionPort :: Prelude.Maybe Prelude.Int
  }
  deriving (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> Bool
(AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> Bool)
-> (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
    -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
    -> Bool)
-> Eq AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> Bool
$c/= :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> Bool
== :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> Bool
$c== :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> Bool
Prelude.Eq, ReadPrec [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
ReadPrec AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
Int
-> ReadS AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
ReadS [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
(Int
 -> ReadS AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> ReadS [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
-> ReadPrec
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> ReadPrec
     [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
-> Read AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
$creadListPrec :: ReadPrec [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
readPrec :: ReadPrec AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
$creadPrec :: ReadPrec AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
readList :: ReadS [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
$creadList :: ReadS [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
readsPrec :: Int
-> ReadS AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
$creadsPrec :: Int
-> ReadS AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
Prelude.Read, Int
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> ShowS
[AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails] -> ShowS
AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> String
(Int
 -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> ShowS)
-> (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
    -> String)
-> ([AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails]
    -> ShowS)
-> Show AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails] -> ShowS
$cshowList :: [AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails] -> ShowS
show :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> String
$cshow :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> String
showsPrec :: Int
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> ShowS
$cshowsPrec :: Int
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> ShowS
Prelude.Show, (forall x.
 AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> Rep AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails x)
-> (forall x.
    Rep AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails x
    -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Generic AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
forall x.
Rep AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails x
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
forall x.
AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Rep AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails x
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
$cfrom :: forall x.
AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Rep AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails x
Prelude.Generic)

-- |
-- Create a value of 'AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'rootDirectory', 'awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_rootDirectory' - The directory within the Amazon EFS file system to mount as the root
-- directory inside the host.
--
-- 'transitEncryption', 'awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_transitEncryption' - Whether to enable encryption for Amazon EFS data in transit between the
-- Amazon ECS host and the Amazon EFS server.
--
-- 'filesystemId', 'awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_filesystemId' - The Amazon EFS file system identifier to use.
--
-- 'authorizationConfig', 'awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_authorizationConfig' - The authorization configuration details for the Amazon EFS file system.
--
-- 'transitEncryptionPort', 'awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_transitEncryptionPort' - The port to use when sending encrypted data between the Amazon ECS host
-- and the Amazon EFS server.
newAwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails ::
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
newAwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
newAwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails =
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
-> Maybe Int
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails'
    { $sel:rootDirectory:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Text
rootDirectory =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:transitEncryption:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Text
transitEncryption =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:filesystemId:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Text
filesystemId =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:authorizationConfig:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
authorizationConfig =
        Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
forall a. Maybe a
Prelude.Nothing,
      $sel:transitEncryptionPort:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Int
transitEncryptionPort =
        Maybe Int
forall a. Maybe a
Prelude.Nothing
    }

-- | The directory within the Amazon EFS file system to mount as the root
-- directory inside the host.
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_rootDirectory :: Lens.Lens' AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails (Prelude.Maybe Prelude.Text)
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_rootDirectory :: (Maybe Text -> f (Maybe Text))
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> f AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_rootDirectory = (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> Maybe Text)
-> (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
    -> Maybe Text
    -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Lens
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {Maybe Text
rootDirectory :: Maybe Text
$sel:rootDirectory:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
rootDirectory} -> Maybe Text
rootDirectory) (\s :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s@AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {} Maybe Text
a -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s {$sel:rootDirectory:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Text
rootDirectory = Maybe Text
a} :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)

-- | Whether to enable encryption for Amazon EFS data in transit between the
-- Amazon ECS host and the Amazon EFS server.
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_transitEncryption :: Lens.Lens' AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails (Prelude.Maybe Prelude.Text)
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_transitEncryption :: (Maybe Text -> f (Maybe Text))
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> f AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_transitEncryption = (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> Maybe Text)
-> (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
    -> Maybe Text
    -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Lens
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {Maybe Text
transitEncryption :: Maybe Text
$sel:transitEncryption:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
transitEncryption} -> Maybe Text
transitEncryption) (\s :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s@AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {} Maybe Text
a -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s {$sel:transitEncryption:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Text
transitEncryption = Maybe Text
a} :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)

-- | The Amazon EFS file system identifier to use.
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_filesystemId :: Lens.Lens' AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails (Prelude.Maybe Prelude.Text)
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_filesystemId :: (Maybe Text -> f (Maybe Text))
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> f AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_filesystemId = (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> Maybe Text)
-> (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
    -> Maybe Text
    -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Lens
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {Maybe Text
filesystemId :: Maybe Text
$sel:filesystemId:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
filesystemId} -> Maybe Text
filesystemId) (\s :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s@AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {} Maybe Text
a -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s {$sel:filesystemId:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Text
filesystemId = Maybe Text
a} :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)

-- | The authorization configuration details for the Amazon EFS file system.
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_authorizationConfig :: Lens.Lens' AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails (Prelude.Maybe AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails)
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_authorizationConfig :: (Maybe
   AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
 -> f (Maybe
         AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails))
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> f AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_authorizationConfig = (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> Maybe
      AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails)
-> (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
    -> Maybe
         AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
    -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Lens
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     (Maybe
        AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails)
     (Maybe
        AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
authorizationConfig :: Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
$sel:authorizationConfig:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
authorizationConfig} -> Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
authorizationConfig) (\s :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s@AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {} Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
a -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s {$sel:authorizationConfig:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
authorizationConfig = Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
a} :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)

-- | The port to use when sending encrypted data between the Amazon ECS host
-- and the Amazon EFS server.
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_transitEncryptionPort :: Lens.Lens' AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails (Prelude.Maybe Prelude.Int)
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_transitEncryptionPort :: (Maybe Int -> f (Maybe Int))
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> f AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
awsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails_transitEncryptionPort = (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
 -> Maybe Int)
-> (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
    -> Maybe Int
    -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Lens
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {Maybe Int
transitEncryptionPort :: Maybe Int
$sel:transitEncryptionPort:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Int
transitEncryptionPort} -> Maybe Int
transitEncryptionPort) (\s :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s@AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {} Maybe Int
a -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
s {$sel:transitEncryptionPort:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: Maybe Int
transitEncryptionPort = Maybe Int
a} :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)

instance
  Core.FromJSON
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
  where
  parseJSON :: Value
-> Parser AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
parseJSON =
    String
-> (Object
    -> Parser AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Value
-> Parser AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails"
      ( \Object
x ->
          Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
-> Maybe Int
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails'
            (Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe
      AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
 -> Maybe Int
 -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe
           AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
      -> Maybe Int
      -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
forall (f :: * -> *) a b. Functor 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
"RootDirectory")
              Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe
        AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
   -> Maybe Int
   -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe
           AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
      -> Maybe Int
      -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
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
"TransitEncryption")
              Parser
  (Maybe Text
   -> Maybe
        AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
   -> Maybe Int
   -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe
        AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
      -> Maybe Int
      -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
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
"FilesystemId")
              Parser
  (Maybe
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
   -> Maybe Int
   -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Parser
     (Maybe
        AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails)
-> Parser
     (Maybe Int
      -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object
-> Text
-> Parser
     (Maybe
        AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AuthorizationConfig")
              Parser
  (Maybe Int
   -> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails)
-> Parser (Maybe Int)
-> Parser AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TransitEncryptionPort")
      )

instance
  Prelude.Hashable
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails

instance
  Prelude.NFData
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails

instance
  Core.ToJSON
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
  where
  toJSON :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails -> Value
toJSON
    AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' {Maybe Int
Maybe Text
Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
transitEncryptionPort :: Maybe Int
authorizationConfig :: Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
filesystemId :: Maybe Text
transitEncryption :: Maybe Text
rootDirectory :: Maybe Text
$sel:transitEncryptionPort:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Int
$sel:authorizationConfig:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
$sel:filesystemId:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
$sel:transitEncryption:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
$sel:rootDirectory:AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails' :: AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationDetails
-> Maybe Text
..} =
      [Pair] -> Value
Core.object
        ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
            [ (Text
"RootDirectory" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
rootDirectory,
              (Text
"TransitEncryption" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
                (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
transitEncryption,
              (Text
"FilesystemId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
filesystemId,
              (Text
"AuthorizationConfig" Text
-> AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
-> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
                (AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
 -> Pair)
-> Maybe
     AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
-> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe
  AwsEcsTaskDefinitionVolumesEfsVolumeConfigurationAuthorizationConfigDetails
authorizationConfig,
              (Text
"TransitEncryptionPort" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
                (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
transitEncryptionPort
            ]
        )