{-# 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.AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-- 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.AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | A host device to expose to the container.
--
-- /See:/ 'newAwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' smart constructor.
data AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails = AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails'
  { -- | The path inside the container at which to expose the host device.
    AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe Text
containerPath :: Prelude.Maybe Prelude.Text,
    -- | The path for the device on the host container instance.
    AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe Text
hostPath :: Prelude.Maybe Prelude.Text,
    -- | The explicit permissions to provide to the container for the device. By
    -- default, the container has permissions for read, write, and @mknod@ for
    -- the device.
    AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe [Text]
permissions :: Prelude.Maybe [Prelude.Text]
  }
  deriving (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Bool
(AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
 -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
 -> Bool)
-> (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
    -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
    -> Bool)
-> Eq
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Bool
$c/= :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Bool
== :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Bool
$c== :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Bool
Prelude.Eq, ReadPrec
  [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
ReadPrec
  AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
Int
-> ReadS
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
ReadS
  [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
(Int
 -> ReadS
      AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> ReadS
     [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
-> ReadPrec
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> ReadPrec
     [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
-> Read
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec
  [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
$creadListPrec :: ReadPrec
  [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
readPrec :: ReadPrec
  AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
$creadPrec :: ReadPrec
  AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
readList :: ReadS
  [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
$creadList :: ReadS
  [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
readsPrec :: Int
-> ReadS
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
$creadsPrec :: Int
-> ReadS
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
Prelude.Read, Int
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> ShowS
[AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
-> ShowS
AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> String
(Int
 -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
 -> ShowS)
-> (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
    -> String)
-> ([AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
    -> ShowS)
-> Show
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
-> ShowS
$cshowList :: [AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails]
-> ShowS
show :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> String
$cshow :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> String
showsPrec :: Int
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> ShowS
$cshowsPrec :: Int
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> ShowS
Prelude.Show, (forall x.
 AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
 -> Rep
      AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
      x)
-> (forall x.
    Rep
      AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
      x
    -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> Generic
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
forall x.
Rep
  AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
  x
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
forall x.
AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Rep
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
     x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep
  AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
  x
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
$cfrom :: forall x.
AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Rep
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
     x
Prelude.Generic)

-- |
-- Create a value of 'AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' 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:
--
-- 'containerPath', 'awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_containerPath' - The path inside the container at which to expose the host device.
--
-- 'hostPath', 'awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_hostPath' - The path for the device on the host container instance.
--
-- 'permissions', 'awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_permissions' - The explicit permissions to provide to the container for the device. By
-- default, the container has permissions for read, write, and @mknod@ for
-- the device.
newAwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails ::
  AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
newAwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
newAwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails =
  AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: Maybe Text
-> Maybe Text
-> Maybe [Text]
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails'
    { $sel:containerPath:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: Maybe Text
containerPath =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:hostPath:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: Maybe Text
hostPath =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:permissions:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: Maybe [Text]
permissions =
        Maybe [Text]
forall a. Maybe a
Prelude.Nothing
    }

-- | The path inside the container at which to expose the host device.
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_containerPath :: Lens.Lens' AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails (Prelude.Maybe Prelude.Text)
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_containerPath :: (Maybe Text -> f (Maybe Text))
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> f AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_containerPath = (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
 -> Maybe Text)
-> (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
    -> Maybe Text
    -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> Lens
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' {Maybe Text
containerPath :: Maybe Text
$sel:containerPath:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe Text
containerPath} -> Maybe Text
containerPath) (\s :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
s@AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' {} Maybe Text
a -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
s {$sel:containerPath:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: Maybe Text
containerPath = Maybe Text
a} :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)

-- | The path for the device on the host container instance.
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_hostPath :: Lens.Lens' AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails (Prelude.Maybe Prelude.Text)
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_hostPath :: (Maybe Text -> f (Maybe Text))
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> f AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_hostPath = (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
 -> Maybe Text)
-> (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
    -> Maybe Text
    -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> Lens
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' {Maybe Text
hostPath :: Maybe Text
$sel:hostPath:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe Text
hostPath} -> Maybe Text
hostPath) (\s :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
s@AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' {} Maybe Text
a -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
s {$sel:hostPath:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: Maybe Text
hostPath = Maybe Text
a} :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)

-- | The explicit permissions to provide to the container for the device. By
-- default, the container has permissions for read, write, and @mknod@ for
-- the device.
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_permissions :: Lens.Lens' AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails (Prelude.Maybe [Prelude.Text])
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_permissions :: (Maybe [Text] -> f (Maybe [Text]))
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> f AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
awsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails_permissions = (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
 -> Maybe [Text])
-> (AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
    -> Maybe [Text]
    -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> Lens
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
     (Maybe [Text])
     (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' {Maybe [Text]
permissions :: Maybe [Text]
$sel:permissions:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe [Text]
permissions} -> Maybe [Text]
permissions) (\s :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
s@AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' {} Maybe [Text]
a -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
s {$sel:permissions:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: Maybe [Text]
permissions = Maybe [Text]
a} :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails) ((Maybe [Text] -> f (Maybe [Text]))
 -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
 -> f AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> f AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

instance
  Core.FromJSON
    AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
  where
  parseJSON :: Value
-> Parser
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
parseJSON =
    String
-> (Object
    -> Parser
         AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> Value
-> Parser
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails"
      ( \Object
x ->
          Maybe Text
-> Maybe Text
-> Maybe [Text]
-> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails'
            (Maybe Text
 -> Maybe Text
 -> Maybe [Text]
 -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe [Text]
      -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
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
"ContainerPath")
              Parser
  (Maybe Text
   -> Maybe [Text]
   -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe [Text]
      -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
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
"HostPath")
              Parser
  (Maybe [Text]
   -> AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails)
-> Parser (Maybe [Text])
-> Parser
     AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Permissions" Parser (Maybe (Maybe [Text]))
-> Maybe [Text] -> Parser (Maybe [Text])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
      )

instance
  Prelude.Hashable
    AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails

instance
  Prelude.NFData
    AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails

instance
  Core.ToJSON
    AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
  where
  toJSON :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Value
toJSON
    AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' {Maybe [Text]
Maybe Text
permissions :: Maybe [Text]
hostPath :: Maybe Text
containerPath :: Maybe Text
$sel:permissions:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe [Text]
$sel:hostPath:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe Text
$sel:containerPath:AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails' :: AwsEcsTaskDefinitionContainerDefinitionsLinuxParametersDevicesDetails
-> Maybe Text
..} =
      [Pair] -> Value
Core.object
        ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
            [ (Text
"ContainerPath" 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
containerPath,
              (Text
"HostPath" 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
hostPath,
              (Text
"Permissions" 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]
permissions
            ]
        )