Get started with Pulumi in a free one hour introductory workshop. Register Now

GetImage

Provides information about a Linode image

Attributes

The Linode Image resource exports the following attributes:

  • label - A short description of the Image.

  • created - When this Image was created.

  • created_by - The name of the User who created this Image, or “linode” for official Images.

  • deprecated - Whether or not this Image is deprecated. Will only be true for deprecated public Images.

  • description - A detailed description of this Image.

  • is_public - True if the Image is public.

  • size - The minimum size this Image needs to deploy. Size is in MB. example: 2500

  • type - How the Image was created. Manual Images can be created at any time. image”Automatic” Images are created automatically from a deleted Linode.

  • vendor - The upstream distribution vendor. None for private Images.

Example Usage

using Pulumi;
using Linode = Pulumi.Linode;

class MyStack : Stack
{
    public MyStack()
    {
        var k8Master = Output.Create(Linode.GetImage.InvokeAsync(new Linode.GetImageArgs
        {
            Id = "linode/debian8",
        }));
    }

}
package main

import (
    "github.com/pulumi/pulumi-linode/sdk/v2/go/linode"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        _, err := linode.LookupImage(ctx, &linode.LookupImageArgs{
            Id: "linode/debian8",
        }, nil)
        if err != nil {
            return err
        }
        return nil
    })
}
import pulumi
import pulumi_linode as linode

k8_master = linode.get_image(id="linode/debian8")
import * as pulumi from "@pulumi/pulumi";
import * as linode from "@pulumi/linode";

const k8Master = pulumi.output(linode.getImage({
    id: "linode/debian8",
}, { async: true }));

Using GetImage

function getImage(args: GetImageArgs, opts?: InvokeOptions): Promise<GetImageResult>
def get_image(id: Optional[str] = None, opts: Optional[InvokeOptions] = None) -> GetImageResult
func LookupImage(ctx *Context, args *LookupImageArgs, opts ...InvokeOption) (*LookupImageResult, error)

Note: This function is named LookupImage in the Go SDK.

public static class GetImage {
    public static Task<GetImageResult> InvokeAsync(GetImageArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

Id string

The unique ID of this Image. The ID of private images begin with private/ followed by the numeric identifier of the private image, for example private/12345.

Id string

The unique ID of this Image. The ID of private images begin with private/ followed by the numeric identifier of the private image, for example private/12345.

id string

The unique ID of this Image. The ID of private images begin with private/ followed by the numeric identifier of the private image, for example private/12345.

id str

The unique ID of this Image. The ID of private images begin with private/ followed by the numeric identifier of the private image, for example private/12345.

GetImage Result

The following output properties are available:

Created string
CreatedBy string
Deprecated bool
Description string
Expiry string
Id string
IsPublic bool
Label string
Size int
Type string
Vendor string
Created string
CreatedBy string
Deprecated bool
Description string
Expiry string
Id string
IsPublic bool
Label string
Size int
Type string
Vendor string
created string
createdBy string
deprecated boolean
description string
expiry string
id string
isPublic boolean
label string
size number
type string
vendor string
created str
created_by str
deprecated bool
description str
expiry str
id str
is_public bool
label str
size int
type str
vendor str

Package Details

Repository
https://github.com/pulumi/pulumi-linode
License
Apache-2.0
Notes
This Pulumi package is based on the linode Terraform Provider.