{-# 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.EKS.Types.VpcConfigRequest
-- 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.EKS.Types.VpcConfigRequest where

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

-- | An object representing the VPC configuration to use for an Amazon EKS
-- cluster.
--
-- /See:/ 'newVpcConfigRequest' smart constructor.
data VpcConfigRequest = VpcConfigRequest'
  { -- | Specify one or more security groups for the cross-account elastic
    -- network interfaces that Amazon EKS creates to use that allow
    -- communication between your nodes and the Kubernetes control plane. If
    -- you don\'t specify any security groups, then familiarize yourself with
    -- the difference between Amazon EKS defaults for clusters deployed with
    -- Kubernetes:
    --
    -- -   1.14 Amazon EKS platform version @eks.2@ and earlier
    --
    -- -   1.14 Amazon EKS platform version @eks.3@ and later
    --
    -- For more information, see
    -- <https://docs.aws.amazon.com/eks/latest/userguide/sec-group-reqs.html Amazon EKS security group considerations>
    -- in the //Amazon EKS User Guide// .
    VpcConfigRequest -> Maybe [Text]
securityGroupIds :: Prelude.Maybe [Prelude.Text],
    -- | Set this value to @true@ to enable private access for your cluster\'s
    -- Kubernetes API server endpoint. If you enable private access, Kubernetes
    -- API requests from within your cluster\'s VPC use the private VPC
    -- endpoint. The default value for this parameter is @false@, which
    -- disables private access for your Kubernetes API server. If you disable
    -- private access and you have nodes or Fargate pods in the cluster, then
    -- ensure that @publicAccessCidrs@ includes the necessary CIDR blocks for
    -- communication with the nodes or Fargate pods. For more information, see
    -- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
    -- in the //Amazon EKS User Guide// .
    VpcConfigRequest -> Maybe Bool
endpointPrivateAccess :: Prelude.Maybe Prelude.Bool,
    -- | The CIDR blocks that are allowed access to your cluster\'s public
    -- Kubernetes API server endpoint. Communication to the endpoint from
    -- addresses outside of the CIDR blocks that you specify is denied. The
    -- default value is @0.0.0.0\/0@. If you\'ve disabled private endpoint
    -- access and you have nodes or Fargate pods in the cluster, then ensure
    -- that you specify the necessary CIDR blocks. For more information, see
    -- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
    -- in the //Amazon EKS User Guide// .
    VpcConfigRequest -> Maybe [Text]
publicAccessCidrs :: Prelude.Maybe [Prelude.Text],
    -- | Specify subnets for your Amazon EKS nodes. Amazon EKS creates
    -- cross-account elastic network interfaces in these subnets to allow
    -- communication between your nodes and the Kubernetes control plane.
    VpcConfigRequest -> Maybe [Text]
subnetIds :: Prelude.Maybe [Prelude.Text],
    -- | Set this value to @false@ to disable public access to your cluster\'s
    -- Kubernetes API server endpoint. If you disable public access, your
    -- cluster\'s Kubernetes API server can only receive requests from within
    -- the cluster VPC. The default value for this parameter is @true@, which
    -- enables public access for your Kubernetes API server. For more
    -- information, see
    -- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
    -- in the //Amazon EKS User Guide// .
    VpcConfigRequest -> Maybe Bool
endpointPublicAccess :: Prelude.Maybe Prelude.Bool
  }
  deriving (VpcConfigRequest -> VpcConfigRequest -> Bool
(VpcConfigRequest -> VpcConfigRequest -> Bool)
-> (VpcConfigRequest -> VpcConfigRequest -> Bool)
-> Eq VpcConfigRequest
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: VpcConfigRequest -> VpcConfigRequest -> Bool
$c/= :: VpcConfigRequest -> VpcConfigRequest -> Bool
== :: VpcConfigRequest -> VpcConfigRequest -> Bool
$c== :: VpcConfigRequest -> VpcConfigRequest -> Bool
Prelude.Eq, ReadPrec [VpcConfigRequest]
ReadPrec VpcConfigRequest
Int -> ReadS VpcConfigRequest
ReadS [VpcConfigRequest]
(Int -> ReadS VpcConfigRequest)
-> ReadS [VpcConfigRequest]
-> ReadPrec VpcConfigRequest
-> ReadPrec [VpcConfigRequest]
-> Read VpcConfigRequest
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [VpcConfigRequest]
$creadListPrec :: ReadPrec [VpcConfigRequest]
readPrec :: ReadPrec VpcConfigRequest
$creadPrec :: ReadPrec VpcConfigRequest
readList :: ReadS [VpcConfigRequest]
$creadList :: ReadS [VpcConfigRequest]
readsPrec :: Int -> ReadS VpcConfigRequest
$creadsPrec :: Int -> ReadS VpcConfigRequest
Prelude.Read, Int -> VpcConfigRequest -> ShowS
[VpcConfigRequest] -> ShowS
VpcConfigRequest -> String
(Int -> VpcConfigRequest -> ShowS)
-> (VpcConfigRequest -> String)
-> ([VpcConfigRequest] -> ShowS)
-> Show VpcConfigRequest
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [VpcConfigRequest] -> ShowS
$cshowList :: [VpcConfigRequest] -> ShowS
show :: VpcConfigRequest -> String
$cshow :: VpcConfigRequest -> String
showsPrec :: Int -> VpcConfigRequest -> ShowS
$cshowsPrec :: Int -> VpcConfigRequest -> ShowS
Prelude.Show, (forall x. VpcConfigRequest -> Rep VpcConfigRequest x)
-> (forall x. Rep VpcConfigRequest x -> VpcConfigRequest)
-> Generic VpcConfigRequest
forall x. Rep VpcConfigRequest x -> VpcConfigRequest
forall x. VpcConfigRequest -> Rep VpcConfigRequest x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep VpcConfigRequest x -> VpcConfigRequest
$cfrom :: forall x. VpcConfigRequest -> Rep VpcConfigRequest x
Prelude.Generic)

-- |
-- Create a value of 'VpcConfigRequest' 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:
--
-- 'securityGroupIds', 'vpcConfigRequest_securityGroupIds' - Specify one or more security groups for the cross-account elastic
-- network interfaces that Amazon EKS creates to use that allow
-- communication between your nodes and the Kubernetes control plane. If
-- you don\'t specify any security groups, then familiarize yourself with
-- the difference between Amazon EKS defaults for clusters deployed with
-- Kubernetes:
--
-- -   1.14 Amazon EKS platform version @eks.2@ and earlier
--
-- -   1.14 Amazon EKS platform version @eks.3@ and later
--
-- For more information, see
-- <https://docs.aws.amazon.com/eks/latest/userguide/sec-group-reqs.html Amazon EKS security group considerations>
-- in the //Amazon EKS User Guide// .
--
-- 'endpointPrivateAccess', 'vpcConfigRequest_endpointPrivateAccess' - Set this value to @true@ to enable private access for your cluster\'s
-- Kubernetes API server endpoint. If you enable private access, Kubernetes
-- API requests from within your cluster\'s VPC use the private VPC
-- endpoint. The default value for this parameter is @false@, which
-- disables private access for your Kubernetes API server. If you disable
-- private access and you have nodes or Fargate pods in the cluster, then
-- ensure that @publicAccessCidrs@ includes the necessary CIDR blocks for
-- communication with the nodes or Fargate pods. For more information, see
-- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
-- in the //Amazon EKS User Guide// .
--
-- 'publicAccessCidrs', 'vpcConfigRequest_publicAccessCidrs' - The CIDR blocks that are allowed access to your cluster\'s public
-- Kubernetes API server endpoint. Communication to the endpoint from
-- addresses outside of the CIDR blocks that you specify is denied. The
-- default value is @0.0.0.0\/0@. If you\'ve disabled private endpoint
-- access and you have nodes or Fargate pods in the cluster, then ensure
-- that you specify the necessary CIDR blocks. For more information, see
-- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
-- in the //Amazon EKS User Guide// .
--
-- 'subnetIds', 'vpcConfigRequest_subnetIds' - Specify subnets for your Amazon EKS nodes. Amazon EKS creates
-- cross-account elastic network interfaces in these subnets to allow
-- communication between your nodes and the Kubernetes control plane.
--
-- 'endpointPublicAccess', 'vpcConfigRequest_endpointPublicAccess' - Set this value to @false@ to disable public access to your cluster\'s
-- Kubernetes API server endpoint. If you disable public access, your
-- cluster\'s Kubernetes API server can only receive requests from within
-- the cluster VPC. The default value for this parameter is @true@, which
-- enables public access for your Kubernetes API server. For more
-- information, see
-- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
-- in the //Amazon EKS User Guide// .
newVpcConfigRequest ::
  VpcConfigRequest
newVpcConfigRequest :: VpcConfigRequest
newVpcConfigRequest =
  VpcConfigRequest' :: Maybe [Text]
-> Maybe Bool
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Bool
-> VpcConfigRequest
VpcConfigRequest'
    { $sel:securityGroupIds:VpcConfigRequest' :: Maybe [Text]
securityGroupIds =
        Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:endpointPrivateAccess:VpcConfigRequest' :: Maybe Bool
endpointPrivateAccess = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:publicAccessCidrs:VpcConfigRequest' :: Maybe [Text]
publicAccessCidrs = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:subnetIds:VpcConfigRequest' :: Maybe [Text]
subnetIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:endpointPublicAccess:VpcConfigRequest' :: Maybe Bool
endpointPublicAccess = Maybe Bool
forall a. Maybe a
Prelude.Nothing
    }

-- | Specify one or more security groups for the cross-account elastic
-- network interfaces that Amazon EKS creates to use that allow
-- communication between your nodes and the Kubernetes control plane. If
-- you don\'t specify any security groups, then familiarize yourself with
-- the difference between Amazon EKS defaults for clusters deployed with
-- Kubernetes:
--
-- -   1.14 Amazon EKS platform version @eks.2@ and earlier
--
-- -   1.14 Amazon EKS platform version @eks.3@ and later
--
-- For more information, see
-- <https://docs.aws.amazon.com/eks/latest/userguide/sec-group-reqs.html Amazon EKS security group considerations>
-- in the //Amazon EKS User Guide// .
vpcConfigRequest_securityGroupIds :: Lens.Lens' VpcConfigRequest (Prelude.Maybe [Prelude.Text])
vpcConfigRequest_securityGroupIds :: (Maybe [Text] -> f (Maybe [Text]))
-> VpcConfigRequest -> f VpcConfigRequest
vpcConfigRequest_securityGroupIds = (VpcConfigRequest -> Maybe [Text])
-> (VpcConfigRequest -> Maybe [Text] -> VpcConfigRequest)
-> Lens
     VpcConfigRequest VpcConfigRequest (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VpcConfigRequest' {Maybe [Text]
securityGroupIds :: Maybe [Text]
$sel:securityGroupIds:VpcConfigRequest' :: VpcConfigRequest -> Maybe [Text]
securityGroupIds} -> Maybe [Text]
securityGroupIds) (\s :: VpcConfigRequest
s@VpcConfigRequest' {} Maybe [Text]
a -> VpcConfigRequest
s {$sel:securityGroupIds:VpcConfigRequest' :: Maybe [Text]
securityGroupIds = Maybe [Text]
a} :: VpcConfigRequest) ((Maybe [Text] -> f (Maybe [Text]))
 -> VpcConfigRequest -> f VpcConfigRequest)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> VpcConfigRequest
-> f VpcConfigRequest
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

-- | Set this value to @true@ to enable private access for your cluster\'s
-- Kubernetes API server endpoint. If you enable private access, Kubernetes
-- API requests from within your cluster\'s VPC use the private VPC
-- endpoint. The default value for this parameter is @false@, which
-- disables private access for your Kubernetes API server. If you disable
-- private access and you have nodes or Fargate pods in the cluster, then
-- ensure that @publicAccessCidrs@ includes the necessary CIDR blocks for
-- communication with the nodes or Fargate pods. For more information, see
-- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
-- in the //Amazon EKS User Guide// .
vpcConfigRequest_endpointPrivateAccess :: Lens.Lens' VpcConfigRequest (Prelude.Maybe Prelude.Bool)
vpcConfigRequest_endpointPrivateAccess :: (Maybe Bool -> f (Maybe Bool))
-> VpcConfigRequest -> f VpcConfigRequest
vpcConfigRequest_endpointPrivateAccess = (VpcConfigRequest -> Maybe Bool)
-> (VpcConfigRequest -> Maybe Bool -> VpcConfigRequest)
-> Lens VpcConfigRequest VpcConfigRequest (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VpcConfigRequest' {Maybe Bool
endpointPrivateAccess :: Maybe Bool
$sel:endpointPrivateAccess:VpcConfigRequest' :: VpcConfigRequest -> Maybe Bool
endpointPrivateAccess} -> Maybe Bool
endpointPrivateAccess) (\s :: VpcConfigRequest
s@VpcConfigRequest' {} Maybe Bool
a -> VpcConfigRequest
s {$sel:endpointPrivateAccess:VpcConfigRequest' :: Maybe Bool
endpointPrivateAccess = Maybe Bool
a} :: VpcConfigRequest)

-- | The CIDR blocks that are allowed access to your cluster\'s public
-- Kubernetes API server endpoint. Communication to the endpoint from
-- addresses outside of the CIDR blocks that you specify is denied. The
-- default value is @0.0.0.0\/0@. If you\'ve disabled private endpoint
-- access and you have nodes or Fargate pods in the cluster, then ensure
-- that you specify the necessary CIDR blocks. For more information, see
-- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
-- in the //Amazon EKS User Guide// .
vpcConfigRequest_publicAccessCidrs :: Lens.Lens' VpcConfigRequest (Prelude.Maybe [Prelude.Text])
vpcConfigRequest_publicAccessCidrs :: (Maybe [Text] -> f (Maybe [Text]))
-> VpcConfigRequest -> f VpcConfigRequest
vpcConfigRequest_publicAccessCidrs = (VpcConfigRequest -> Maybe [Text])
-> (VpcConfigRequest -> Maybe [Text] -> VpcConfigRequest)
-> Lens
     VpcConfigRequest VpcConfigRequest (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VpcConfigRequest' {Maybe [Text]
publicAccessCidrs :: Maybe [Text]
$sel:publicAccessCidrs:VpcConfigRequest' :: VpcConfigRequest -> Maybe [Text]
publicAccessCidrs} -> Maybe [Text]
publicAccessCidrs) (\s :: VpcConfigRequest
s@VpcConfigRequest' {} Maybe [Text]
a -> VpcConfigRequest
s {$sel:publicAccessCidrs:VpcConfigRequest' :: Maybe [Text]
publicAccessCidrs = Maybe [Text]
a} :: VpcConfigRequest) ((Maybe [Text] -> f (Maybe [Text]))
 -> VpcConfigRequest -> f VpcConfigRequest)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> VpcConfigRequest
-> f VpcConfigRequest
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

-- | Specify subnets for your Amazon EKS nodes. Amazon EKS creates
-- cross-account elastic network interfaces in these subnets to allow
-- communication between your nodes and the Kubernetes control plane.
vpcConfigRequest_subnetIds :: Lens.Lens' VpcConfigRequest (Prelude.Maybe [Prelude.Text])
vpcConfigRequest_subnetIds :: (Maybe [Text] -> f (Maybe [Text]))
-> VpcConfigRequest -> f VpcConfigRequest
vpcConfigRequest_subnetIds = (VpcConfigRequest -> Maybe [Text])
-> (VpcConfigRequest -> Maybe [Text] -> VpcConfigRequest)
-> Lens
     VpcConfigRequest VpcConfigRequest (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VpcConfigRequest' {Maybe [Text]
subnetIds :: Maybe [Text]
$sel:subnetIds:VpcConfigRequest' :: VpcConfigRequest -> Maybe [Text]
subnetIds} -> Maybe [Text]
subnetIds) (\s :: VpcConfigRequest
s@VpcConfigRequest' {} Maybe [Text]
a -> VpcConfigRequest
s {$sel:subnetIds:VpcConfigRequest' :: Maybe [Text]
subnetIds = Maybe [Text]
a} :: VpcConfigRequest) ((Maybe [Text] -> f (Maybe [Text]))
 -> VpcConfigRequest -> f VpcConfigRequest)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> VpcConfigRequest
-> f VpcConfigRequest
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

-- | Set this value to @false@ to disable public access to your cluster\'s
-- Kubernetes API server endpoint. If you disable public access, your
-- cluster\'s Kubernetes API server can only receive requests from within
-- the cluster VPC. The default value for this parameter is @true@, which
-- enables public access for your Kubernetes API server. For more
-- information, see
-- <https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html Amazon EKS cluster endpoint access control>
-- in the //Amazon EKS User Guide// .
vpcConfigRequest_endpointPublicAccess :: Lens.Lens' VpcConfigRequest (Prelude.Maybe Prelude.Bool)
vpcConfigRequest_endpointPublicAccess :: (Maybe Bool -> f (Maybe Bool))
-> VpcConfigRequest -> f VpcConfigRequest
vpcConfigRequest_endpointPublicAccess = (VpcConfigRequest -> Maybe Bool)
-> (VpcConfigRequest -> Maybe Bool -> VpcConfigRequest)
-> Lens VpcConfigRequest VpcConfigRequest (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VpcConfigRequest' {Maybe Bool
endpointPublicAccess :: Maybe Bool
$sel:endpointPublicAccess:VpcConfigRequest' :: VpcConfigRequest -> Maybe Bool
endpointPublicAccess} -> Maybe Bool
endpointPublicAccess) (\s :: VpcConfigRequest
s@VpcConfigRequest' {} Maybe Bool
a -> VpcConfigRequest
s {$sel:endpointPublicAccess:VpcConfigRequest' :: Maybe Bool
endpointPublicAccess = Maybe Bool
a} :: VpcConfigRequest)

instance Prelude.Hashable VpcConfigRequest

instance Prelude.NFData VpcConfigRequest

instance Core.ToJSON VpcConfigRequest where
  toJSON :: VpcConfigRequest -> Value
toJSON VpcConfigRequest' {Maybe Bool
Maybe [Text]
endpointPublicAccess :: Maybe Bool
subnetIds :: Maybe [Text]
publicAccessCidrs :: Maybe [Text]
endpointPrivateAccess :: Maybe Bool
securityGroupIds :: Maybe [Text]
$sel:endpointPublicAccess:VpcConfigRequest' :: VpcConfigRequest -> Maybe Bool
$sel:subnetIds:VpcConfigRequest' :: VpcConfigRequest -> Maybe [Text]
$sel:publicAccessCidrs:VpcConfigRequest' :: VpcConfigRequest -> Maybe [Text]
$sel:endpointPrivateAccess:VpcConfigRequest' :: VpcConfigRequest -> Maybe Bool
$sel:securityGroupIds:VpcConfigRequest' :: VpcConfigRequest -> Maybe [Text]
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"securityGroupIds" 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]
securityGroupIds,
            (Text
"endpointPrivateAccess" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
endpointPrivateAccess,
            (Text
"publicAccessCidrs" 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]
publicAccessCidrs,
            (Text
"subnetIds" 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]
subnetIds,
            (Text
"endpointPublicAccess" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
endpointPublicAccess
          ]
      )