| 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 |
Amazonka.ImageBuilder.PutComponentPolicy
Description
Applies a policy to a component. We recommend that you call the RAM API
CreateResourceShare
to share resources. If you call the Image Builder API
PutComponentPolicy, you must also call the RAM API
PromoteResourceShareCreatedFromPolicy
in order for the resource to be visible to all principals with whom the
resource is shared.
Synopsis
- data PutComponentPolicy = PutComponentPolicy' {
- componentArn :: Text
- policy :: Text
- newPutComponentPolicy :: Text -> Text -> PutComponentPolicy
- putComponentPolicy_componentArn :: Lens' PutComponentPolicy Text
- putComponentPolicy_policy :: Lens' PutComponentPolicy Text
- data PutComponentPolicyResponse = PutComponentPolicyResponse' {
- componentArn :: Maybe Text
- requestId :: Maybe Text
- httpStatus :: Int
- newPutComponentPolicyResponse :: Int -> PutComponentPolicyResponse
- putComponentPolicyResponse_componentArn :: Lens' PutComponentPolicyResponse (Maybe Text)
- putComponentPolicyResponse_requestId :: Lens' PutComponentPolicyResponse (Maybe Text)
- putComponentPolicyResponse_httpStatus :: Lens' PutComponentPolicyResponse Int
Creating a Request
data PutComponentPolicy Source #
See: newPutComponentPolicy smart constructor.
Constructors
| PutComponentPolicy' | |
Fields
| |
Instances
newPutComponentPolicy Source #
Create a value of PutComponentPolicy 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:
PutComponentPolicy, putComponentPolicy_componentArn - The Amazon Resource Name (ARN) of the component that this policy should
be applied to.
$sel:policy:PutComponentPolicy', putComponentPolicy_policy - The policy to apply.
Request Lenses
putComponentPolicy_componentArn :: Lens' PutComponentPolicy Text Source #
The Amazon Resource Name (ARN) of the component that this policy should be applied to.
putComponentPolicy_policy :: Lens' PutComponentPolicy Text Source #
The policy to apply.
Destructuring the Response
data PutComponentPolicyResponse Source #
See: newPutComponentPolicyResponse smart constructor.
Constructors
| PutComponentPolicyResponse' | |
Fields
| |
Instances
newPutComponentPolicyResponse Source #
Create a value of PutComponentPolicyResponse 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:
PutComponentPolicy, putComponentPolicyResponse_componentArn - The Amazon Resource Name (ARN) of the component that this policy was
applied to.
$sel:requestId:PutComponentPolicyResponse', putComponentPolicyResponse_requestId - The request ID that uniquely identifies this request.
$sel:httpStatus:PutComponentPolicyResponse', putComponentPolicyResponse_httpStatus - The response's http status code.
Response Lenses
putComponentPolicyResponse_componentArn :: Lens' PutComponentPolicyResponse (Maybe Text) Source #
The Amazon Resource Name (ARN) of the component that this policy was applied to.
putComponentPolicyResponse_requestId :: Lens' PutComponentPolicyResponse (Maybe Text) Source #
The request ID that uniquely identifies this request.
putComponentPolicyResponse_httpStatus :: Lens' PutComponentPolicyResponse Int Source #
The response's http status code.