delete_container_image
async
¶
delete_container_image(
service_name: ContainerServiceName,
image: string,
*,
config_overrides: Optional[AsyncLightsailClientConfig] = None,
) -> DeleteContainerImageResult
Deletes a container image that is registered to your Amazon Lightsail container service.
Parameters:
-
service_name(ContainerServiceName) –The name of the container service for which to delete a registered container image.
-
image(string) –The name of the container image to delete from the container service.
Use the
GetContainerImagesaction to get the name of the container images that are registered to a container service.Container images sourced from your Lightsail container service, that are registered and stored on your service, start with a colon (
:). For example,:container-service-1.mystaticwebsite.1. Container images sourced from a public registry like Docker Hub don't start with a colon. For example,nginx:latestornginx.
Raises:
-
AccessDeniedException–Lightsail throws this exception when the user cannot be authenticated or uses invalid credentials to access a resource.
-
InvalidInputException–Lightsail throws this exception when user input does not conform to the validation rules of an input field.
Domain and distribution APIs are only available in the N. Virginia (
us-east-1) Amazon Web Services Region. Please set your Amazon Web Services Region configuration tous-east-1to create, view, or edit these resources. -
NotFoundException–Lightsail throws this exception when it cannot find a resource.
-
RegionSetupInProgressException–Lightsail throws this exception when an operation is performed on resources in an opt-in Region that is currently being set up.
-
ServiceException–A general service exception.
-
UnauthenticatedException–Lightsail throws this exception when the user has not been authenticated.
-
UnknownServiceError–The service returned an error code this client does not model.