Scaleway v1.20.0 published on Monday, Nov 4, 2024 by pulumiverse
scaleway.getMarketplaceImage
Explore with Pulumi AI
Gets local image ID of an image from its label name.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as scaleway from "@pulumi/scaleway";
const myImage = scaleway.getMarketplaceImage({
label: "ubuntu_jammy",
});
import pulumi
import pulumi_scaleway as scaleway
my_image = scaleway.get_marketplace_image(label="ubuntu_jammy")
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-scaleway/sdk/go/scaleway"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := scaleway.GetMarketplaceImage(ctx, &scaleway.GetMarketplaceImageArgs{
Label: "ubuntu_jammy",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Scaleway = Pulumi.Scaleway;
return await Deployment.RunAsync(() =>
{
var myImage = Scaleway.GetMarketplaceImage.Invoke(new()
{
Label = "ubuntu_jammy",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.scaleway.ScalewayFunctions;
import com.pulumi.scaleway.inputs.GetMarketplaceImageArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var myImage = ScalewayFunctions.getMarketplaceImage(GetMarketplaceImageArgs.builder()
.label("ubuntu_jammy")
.build());
}
}
variables:
myImage:
fn::invoke:
Function: scaleway:getMarketplaceImage
Arguments:
label: ubuntu_jammy
Using getMarketplaceImage
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getMarketplaceImage(args: GetMarketplaceImageArgs, opts?: InvokeOptions): Promise<GetMarketplaceImageResult>
function getMarketplaceImageOutput(args: GetMarketplaceImageOutputArgs, opts?: InvokeOptions): Output<GetMarketplaceImageResult>
def get_marketplace_image(instance_type: Optional[str] = None,
label: Optional[str] = None,
zone: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetMarketplaceImageResult
def get_marketplace_image_output(instance_type: Optional[pulumi.Input[str]] = None,
label: Optional[pulumi.Input[str]] = None,
zone: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetMarketplaceImageResult]
func GetMarketplaceImage(ctx *Context, args *GetMarketplaceImageArgs, opts ...InvokeOption) (*GetMarketplaceImageResult, error)
func GetMarketplaceImageOutput(ctx *Context, args *GetMarketplaceImageOutputArgs, opts ...InvokeOption) GetMarketplaceImageResultOutput
> Note: This function is named GetMarketplaceImage
in the Go SDK.
public static class GetMarketplaceImage
{
public static Task<GetMarketplaceImageResult> InvokeAsync(GetMarketplaceImageArgs args, InvokeOptions? opts = null)
public static Output<GetMarketplaceImageResult> Invoke(GetMarketplaceImageInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetMarketplaceImageResult> getMarketplaceImage(GetMarketplaceImageArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: scaleway:index/getMarketplaceImage:getMarketplaceImage
arguments:
# arguments dictionary
The following arguments are supported:
- Label string
- Exact label of the desired image. You can use this endpoint
to find the right
label
. - Instance
Type string - The instance type the image is compatible with. You find all the available types on the pricing page.
- Zone string
zone
) The zone in which the image exists.
- Label string
- Exact label of the desired image. You can use this endpoint
to find the right
label
. - Instance
Type string - The instance type the image is compatible with. You find all the available types on the pricing page.
- Zone string
zone
) The zone in which the image exists.
- label String
- Exact label of the desired image. You can use this endpoint
to find the right
label
. - instance
Type String - The instance type the image is compatible with. You find all the available types on the pricing page.
- zone String
zone
) The zone in which the image exists.
- label string
- Exact label of the desired image. You can use this endpoint
to find the right
label
. - instance
Type string - The instance type the image is compatible with. You find all the available types on the pricing page.
- zone string
zone
) The zone in which the image exists.
- label str
- Exact label of the desired image. You can use this endpoint
to find the right
label
. - instance_
type str - The instance type the image is compatible with. You find all the available types on the pricing page.
- zone str
zone
) The zone in which the image exists.
- label String
- Exact label of the desired image. You can use this endpoint
to find the right
label
. - instance
Type String - The instance type the image is compatible with. You find all the available types on the pricing page.
- zone String
zone
) The zone in which the image exists.
getMarketplaceImage Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Label string
- Zone string
- Instance
Type string
- Id string
- The provider-assigned unique ID for this managed resource.
- Label string
- Zone string
- Instance
Type string
- id String
- The provider-assigned unique ID for this managed resource.
- label String
- zone String
- instance
Type String
- id string
- The provider-assigned unique ID for this managed resource.
- label string
- zone string
- instance
Type string
- id str
- The provider-assigned unique ID for this managed resource.
- label str
- zone str
- instance_
type str
- id String
- The provider-assigned unique ID for this managed resource.
- label String
- zone String
- instance
Type String
Package Details
- Repository
- scaleway pulumiverse/pulumi-scaleway
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
scaleway
Terraform Provider.