update_license_specifications_for_resource
¶
update_license_specifications_for_resource(
resource_arn: String,
*,
config_overrides: Optional[LicenseManagerClientConfig] = None,
add_license_specifications: Optional[LicenseSpecifications] = None,
remove_license_specifications: Optional[LicenseSpecifications] = None,
) -> UpdateLicenseSpecificationsForResourceResponse
Adds or removes the specified license configurations for the specified Amazon Web Services resource.
You can update the license specifications of AMIs, instances, and hosts. You cannot update the license specifications for launch templates and CloudFormation templates, as they send license configurations to the operation that creates the resource.
Parameters:
-
resource_arn(String) –Amazon Resource Name (ARN) of the Amazon Web Services resource.
-
add_license_specifications(Optional[LicenseSpecifications], default:None) –ARNs of the license configurations to add.
-
remove_license_specifications(Optional[LicenseSpecifications], default:None) –ARNs of the license configurations to remove.
Raises:
-
AccessDeniedException–Access to resource denied.
-
AuthorizationException–The Amazon Web Services user account does not have permission to perform the action. Check the IAM policy associated with this account.
-
ConflictException–There was a conflict processing the request. Try your request again.
-
InvalidParameterValueException–One or more parameter values are not valid.
-
InvalidResourceStateException–License Manager cannot allocate a license to a resource because of its state.
For example, you cannot allocate a license to an instance in the process of shutting down.
-
LicenseUsageException–You do not have enough licenses available to support a new resource launch.
-
RateLimitExceededException–Too many requests have been submitted. Try again after a brief wait.
-
ServerInternalException–The server experienced an internal error. Try again.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_license_manager/_services/license_manager.py
4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 | |