reset_image_attribute
¶
reset_image_attribute(
*,
config_overrides: Optional[EC2ClientConfig] = None,
attribute: Optional[ResetImageAttributeName] = None,
image_id: Optional[ImageId] = None,
dry_run: Optional[Boolean] = None,
) -> None
Resets an attribute of an AMI to its default value.
Parameters:
-
attribute(Optional[ResetImageAttributeName], default:None) –The attribute to reset (currently you can only reset the launch permission attribute).
-
image_id(Optional[ImageId], default:None) –The ID of the AMI.
-
dry_run(Optional[Boolean], default:None) –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 isUnauthorizedOperation.
Raises:
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
To reset the launchPermission attribute This example resets the launchPermission attribute for the specified AMI. By default, AMIs are private.
Source code in docs_src/capo_ec2/_services/ec2.py
57891 57892 57893 57894 57895 57896 57897 57898 57899 57900 57901 57902 57903 57904 57905 57906 57907 57908 57909 57910 57911 57912 57913 57914 57915 57916 57917 57918 57919 57920 57921 57922 57923 57924 57925 57926 57927 57928 57929 57930 57931 57932 57933 57934 57935 57936 57937 57938 57939 57940 57941 57942 57943 57944 57945 57946 57947 | |