Skip to content

DigitalOcean.Images reference

Source: packages/digitalocean/src/Image.ts

A DigitalOcean custom image imported from a URL, to boot droplets from your own OS build. Import takes a few minutes; reconcile returns once the image is available. name, distribution and description update in place; url, region and tags replace the image.

Alchemy knows an image by the id it recorded, or by the name it generated when an import was interrupted before the id was saved.

const image = yield* DigitalOcean.Image("debian", {
url: "https://cloud.debian.org/images/cloud/bookworm/latest/debian-12-generic-amd64.qcow2",
region: "nyc3",
distribution: "Debian",
});
const host = yield* DigitalOcean.Droplet("app", {
region: "nyc3",
size: "s-1vcpu-1gb",
image: image.imageId,
});