module Stratosphere.EKS.Nodegroup.RemoteAccessProperty (
RemoteAccessProperty(..), mkRemoteAccessProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data RemoteAccessProperty
=
RemoteAccessProperty {RemoteAccessProperty -> ()
haddock_workaround_ :: (),
RemoteAccessProperty -> Value Text
ec2SshKey :: (Value Prelude.Text),
RemoteAccessProperty -> Maybe (ValueList Text)
sourceSecurityGroups :: (Prelude.Maybe (ValueList Prelude.Text))}
deriving stock (RemoteAccessProperty -> RemoteAccessProperty -> Bool
(RemoteAccessProperty -> RemoteAccessProperty -> Bool)
-> (RemoteAccessProperty -> RemoteAccessProperty -> Bool)
-> Eq RemoteAccessProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: RemoteAccessProperty -> RemoteAccessProperty -> Bool
== :: RemoteAccessProperty -> RemoteAccessProperty -> Bool
$c/= :: RemoteAccessProperty -> RemoteAccessProperty -> Bool
/= :: RemoteAccessProperty -> RemoteAccessProperty -> Bool
Prelude.Eq, Int -> RemoteAccessProperty -> ShowS
[RemoteAccessProperty] -> ShowS
RemoteAccessProperty -> String
(Int -> RemoteAccessProperty -> ShowS)
-> (RemoteAccessProperty -> String)
-> ([RemoteAccessProperty] -> ShowS)
-> Show RemoteAccessProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> RemoteAccessProperty -> ShowS
showsPrec :: Int -> RemoteAccessProperty -> ShowS
$cshow :: RemoteAccessProperty -> String
show :: RemoteAccessProperty -> String
$cshowList :: [RemoteAccessProperty] -> ShowS
showList :: [RemoteAccessProperty] -> ShowS
Prelude.Show)
mkRemoteAccessProperty ::
Value Prelude.Text -> RemoteAccessProperty
mkRemoteAccessProperty :: Value Text -> RemoteAccessProperty
mkRemoteAccessProperty Value Text
ec2SshKey
= RemoteAccessProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), ec2SshKey :: Value Text
ec2SshKey = Value Text
ec2SshKey,
sourceSecurityGroups :: Maybe (ValueList Text)
sourceSecurityGroups = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties RemoteAccessProperty where
toResourceProperties :: RemoteAccessProperty -> ResourceProperties
toResourceProperties RemoteAccessProperty {Maybe (ValueList Text)
()
Value Text
haddock_workaround_ :: RemoteAccessProperty -> ()
ec2SshKey :: RemoteAccessProperty -> Value Text
sourceSecurityGroups :: RemoteAccessProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
ec2SshKey :: Value Text
sourceSecurityGroups :: Maybe (ValueList Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::EKS::Nodegroup.RemoteAccess",
supportsTags :: Bool
supportsTags = Bool
Prelude.False,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"Ec2SshKey" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
ec2SshKey]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"SourceSecurityGroups"
(ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
sourceSecurityGroups]))}
instance JSON.ToJSON RemoteAccessProperty where
toJSON :: RemoteAccessProperty -> Value
toJSON RemoteAccessProperty {Maybe (ValueList Text)
()
Value Text
haddock_workaround_ :: RemoteAccessProperty -> ()
ec2SshKey :: RemoteAccessProperty -> Value Text
sourceSecurityGroups :: RemoteAccessProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
ec2SshKey :: Value Text
sourceSecurityGroups :: Maybe (ValueList Text)
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"Ec2SshKey" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
ec2SshKey]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"SourceSecurityGroups"
(ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
sourceSecurityGroups])))
instance Property "Ec2SshKey" RemoteAccessProperty where
type PropertyType "Ec2SshKey" RemoteAccessProperty = Value Prelude.Text
set :: PropertyType "Ec2SshKey" RemoteAccessProperty
-> RemoteAccessProperty -> RemoteAccessProperty
set PropertyType "Ec2SshKey" RemoteAccessProperty
newValue RemoteAccessProperty {Maybe (ValueList Text)
()
Value Text
haddock_workaround_ :: RemoteAccessProperty -> ()
ec2SshKey :: RemoteAccessProperty -> Value Text
sourceSecurityGroups :: RemoteAccessProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
ec2SshKey :: Value Text
sourceSecurityGroups :: Maybe (ValueList Text)
..}
= RemoteAccessProperty {ec2SshKey :: Value Text
ec2SshKey = PropertyType "Ec2SshKey" RemoteAccessProperty
Value Text
newValue, Maybe (ValueList Text)
()
haddock_workaround_ :: ()
sourceSecurityGroups :: Maybe (ValueList Text)
haddock_workaround_ :: ()
sourceSecurityGroups :: Maybe (ValueList Text)
..}
instance Property "SourceSecurityGroups" RemoteAccessProperty where
type PropertyType "SourceSecurityGroups" RemoteAccessProperty = ValueList Prelude.Text
set :: PropertyType "SourceSecurityGroups" RemoteAccessProperty
-> RemoteAccessProperty -> RemoteAccessProperty
set PropertyType "SourceSecurityGroups" RemoteAccessProperty
newValue RemoteAccessProperty {Maybe (ValueList Text)
()
Value Text
haddock_workaround_ :: RemoteAccessProperty -> ()
ec2SshKey :: RemoteAccessProperty -> Value Text
sourceSecurityGroups :: RemoteAccessProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
ec2SshKey :: Value Text
sourceSecurityGroups :: Maybe (ValueList Text)
..}
= RemoteAccessProperty
{sourceSecurityGroups :: Maybe (ValueList Text)
sourceSecurityGroups = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "SourceSecurityGroups" RemoteAccessProperty
ValueList Text
newValue, ()
Value Text
haddock_workaround_ :: ()
ec2SshKey :: Value Text
haddock_workaround_ :: ()
ec2SshKey :: Value Text
..}