To cancel the currently-active garbage collection for a registry, send a PUT request to /v2/registry/$REGISTRY_NAME/garbage-collection/$GC_UUID
and specify one or more of the attributes below.
Name | Type | Required | Description | Default Value |
---|---|---|---|---|
registry_name |
string | True | The name of a container registry. | |
garbage_collection_uuid |
string | True | The UUID of a garbage collection run. | |
body |
JSON or IO[bytes] | True |
import os
from pydo import Client
client = Client(token=os.environ.get("DIGITALOCEAN_TOKEN"))
resp = client.registry.run_garbage_collection(registry_name="example")
See the API spec for this endpoint to view additional detail on responses, headers, parameters, and more.