Copyright | (c) 2013-2023 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Enables deprecation of the specified AMI at the specified date and time.
For more information, see Deprecate an AMI in the Amazon EC2 User Guide.
Synopsis
- data EnableImageDeprecation = EnableImageDeprecation' {}
- newEnableImageDeprecation :: Text -> UTCTime -> EnableImageDeprecation
- enableImageDeprecation_dryRun :: Lens' EnableImageDeprecation (Maybe Bool)
- enableImageDeprecation_imageId :: Lens' EnableImageDeprecation Text
- enableImageDeprecation_deprecateAt :: Lens' EnableImageDeprecation UTCTime
- data EnableImageDeprecationResponse = EnableImageDeprecationResponse' {
- return' :: Maybe Bool
- httpStatus :: Int
- newEnableImageDeprecationResponse :: Int -> EnableImageDeprecationResponse
- enableImageDeprecationResponse_return :: Lens' EnableImageDeprecationResponse (Maybe Bool)
- enableImageDeprecationResponse_httpStatus :: Lens' EnableImageDeprecationResponse Int
Creating a Request
data EnableImageDeprecation Source #
See: newEnableImageDeprecation
smart constructor.
EnableImageDeprecation' | |
|
Instances
newEnableImageDeprecation Source #
:: Text | |
-> UTCTime | |
-> EnableImageDeprecation |
Create a value of EnableImageDeprecation
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:dryRun:EnableImageDeprecation'
, enableImageDeprecation_dryRun
- Checks whether you have the required permissions for the action, without
actually making the request, and provides an error response. If you have
the required permissions, the error response is DryRunOperation
.
Otherwise, it is UnauthorizedOperation
.
EnableImageDeprecation
, enableImageDeprecation_imageId
- The ID of the AMI.
$sel:deprecateAt:EnableImageDeprecation'
, enableImageDeprecation_deprecateAt
- The date and time to deprecate the AMI, in UTC, in the following format:
YYYY-MM-DDTHH:MM:SSZ. If you specify a value for seconds,
Amazon EC2 rounds the seconds to the nearest minute.
You can’t specify a date in the past. The upper limit for DeprecateAt
is 10 years from now, except for public AMIs, where the upper limit is 2
years from the creation date.
Request Lenses
enableImageDeprecation_dryRun :: Lens' EnableImageDeprecation (Maybe Bool) Source #
Checks whether you have the required permissions for the action, without
actually making the request, and provides an error response. If you have
the required permissions, the error response is DryRunOperation
.
Otherwise, it is UnauthorizedOperation
.
enableImageDeprecation_imageId :: Lens' EnableImageDeprecation Text Source #
The ID of the AMI.
enableImageDeprecation_deprecateAt :: Lens' EnableImageDeprecation UTCTime Source #
The date and time to deprecate the AMI, in UTC, in the following format: YYYY-MM-DDTHH:MM:SSZ. If you specify a value for seconds, Amazon EC2 rounds the seconds to the nearest minute.
You can’t specify a date in the past. The upper limit for DeprecateAt
is 10 years from now, except for public AMIs, where the upper limit is 2
years from the creation date.
Destructuring the Response
data EnableImageDeprecationResponse Source #
See: newEnableImageDeprecationResponse
smart constructor.
EnableImageDeprecationResponse' | |
|
Instances
Generic EnableImageDeprecationResponse Source # | |
Read EnableImageDeprecationResponse Source # | |
Show EnableImageDeprecationResponse Source # | |
Defined in Amazonka.EC2.EnableImageDeprecation | |
NFData EnableImageDeprecationResponse Source # | |
Defined in Amazonka.EC2.EnableImageDeprecation rnf :: EnableImageDeprecationResponse -> () # | |
Eq EnableImageDeprecationResponse Source # | |
type Rep EnableImageDeprecationResponse Source # | |
Defined in Amazonka.EC2.EnableImageDeprecation type Rep EnableImageDeprecationResponse = D1 ('MetaData "EnableImageDeprecationResponse" "Amazonka.EC2.EnableImageDeprecation" "amazonka-ec2-2.0-48L9RAJvmvzAdBkRegqWCL" 'False) (C1 ('MetaCons "EnableImageDeprecationResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "return'") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))) |
newEnableImageDeprecationResponse Source #
Create a value of EnableImageDeprecationResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:return':EnableImageDeprecationResponse'
, enableImageDeprecationResponse_return
- Returns true
if the request succeeds; otherwise, it returns an error.
$sel:httpStatus:EnableImageDeprecationResponse'
, enableImageDeprecationResponse_httpStatus
- The response's http status code.
Response Lenses
enableImageDeprecationResponse_return :: Lens' EnableImageDeprecationResponse (Maybe Bool) Source #
Returns true
if the request succeeds; otherwise, it returns an error.
enableImageDeprecationResponse_httpStatus :: Lens' EnableImageDeprecationResponse Int Source #
The response's http status code.