1. Packages
  2. Scaleway
  3. API Docs
  4. getBaremetalOption
Scaleway v1.20.0 published on Monday, Nov 4, 2024 by pulumiverse

scaleway.getBaremetalOption

Explore with Pulumi AI

scaleway logo
Scaleway v1.20.0 published on Monday, Nov 4, 2024 by pulumiverse

    Gets information about a baremetal option. For more information, see the documentation.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as scaleway from "@pulumi/scaleway";
    
    // Get info by option name 
    const byName = scaleway.getBaremetalOption({
        name: "Remote Access",
    });
    // Get info by option id
    const byId = scaleway.getBaremetalOption({
        optionId: "931df052-d713-4674-8b58-96a63244c8e2",
    });
    
    import pulumi
    import pulumi_scaleway as scaleway
    
    # Get info by option name 
    by_name = scaleway.get_baremetal_option(name="Remote Access")
    # Get info by option id
    by_id = scaleway.get_baremetal_option(option_id="931df052-d713-4674-8b58-96a63244c8e2")
    
    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 {
    		// Get info by option name
    		_, err := scaleway.GetBaremetalOption(ctx, &scaleway.GetBaremetalOptionArgs{
    			Name: pulumi.StringRef("Remote Access"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		// Get info by option id
    		_, err = scaleway.GetBaremetalOption(ctx, &scaleway.GetBaremetalOptionArgs{
    			OptionId: pulumi.StringRef("931df052-d713-4674-8b58-96a63244c8e2"),
    		}, 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(() => 
    {
        // Get info by option name 
        var byName = Scaleway.GetBaremetalOption.Invoke(new()
        {
            Name = "Remote Access",
        });
    
        // Get info by option id
        var byId = Scaleway.GetBaremetalOption.Invoke(new()
        {
            OptionId = "931df052-d713-4674-8b58-96a63244c8e2",
        });
    
    });
    
    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.GetBaremetalOptionArgs;
    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) {
            // Get info by option name 
            final var byName = ScalewayFunctions.getBaremetalOption(GetBaremetalOptionArgs.builder()
                .name("Remote Access")
                .build());
    
            // Get info by option id
            final var byId = ScalewayFunctions.getBaremetalOption(GetBaremetalOptionArgs.builder()
                .optionId("931df052-d713-4674-8b58-96a63244c8e2")
                .build());
    
        }
    }
    
    variables:
      # Get info by option name
      byName:
        fn::invoke:
          Function: scaleway:getBaremetalOption
          Arguments:
            name: Remote Access
      # Get info by option id
      byId:
        fn::invoke:
          Function: scaleway:getBaremetalOption
          Arguments:
            optionId: 931df052-d713-4674-8b58-96a63244c8e2
    

    Using getBaremetalOption

    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 getBaremetalOption(args: GetBaremetalOptionArgs, opts?: InvokeOptions): Promise<GetBaremetalOptionResult>
    function getBaremetalOptionOutput(args: GetBaremetalOptionOutputArgs, opts?: InvokeOptions): Output<GetBaremetalOptionResult>
    def get_baremetal_option(name: Optional[str] = None,
                             option_id: Optional[str] = None,
                             zone: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetBaremetalOptionResult
    def get_baremetal_option_output(name: Optional[pulumi.Input[str]] = None,
                             option_id: Optional[pulumi.Input[str]] = None,
                             zone: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetBaremetalOptionResult]
    func GetBaremetalOption(ctx *Context, args *GetBaremetalOptionArgs, opts ...InvokeOption) (*GetBaremetalOptionResult, error)
    func GetBaremetalOptionOutput(ctx *Context, args *GetBaremetalOptionOutputArgs, opts ...InvokeOption) GetBaremetalOptionResultOutput

    > Note: This function is named GetBaremetalOption in the Go SDK.

    public static class GetBaremetalOption 
    {
        public static Task<GetBaremetalOptionResult> InvokeAsync(GetBaremetalOptionArgs args, InvokeOptions? opts = null)
        public static Output<GetBaremetalOptionResult> Invoke(GetBaremetalOptionInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetBaremetalOptionResult> getBaremetalOption(GetBaremetalOptionArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: scaleway:index/getBaremetalOption:getBaremetalOption
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Name string
    The option name. Only one of name and option_id should be specified.
    OptionId string
    The option id. Only one of name and option_id should be specified.
    Zone string
    zone) The zone in which the option exists.
    Name string
    The option name. Only one of name and option_id should be specified.
    OptionId string
    The option id. Only one of name and option_id should be specified.
    Zone string
    zone) The zone in which the option exists.
    name String
    The option name. Only one of name and option_id should be specified.
    optionId String
    The option id. Only one of name and option_id should be specified.
    zone String
    zone) The zone in which the option exists.
    name string
    The option name. Only one of name and option_id should be specified.
    optionId string
    The option id. Only one of name and option_id should be specified.
    zone string
    zone) The zone in which the option exists.
    name str
    The option name. Only one of name and option_id should be specified.
    option_id str
    The option id. Only one of name and option_id should be specified.
    zone str
    zone) The zone in which the option exists.
    name String
    The option name. Only one of name and option_id should be specified.
    optionId String
    The option id. Only one of name and option_id should be specified.
    zone String
    zone) The zone in which the option exists.

    getBaremetalOption Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Manageable bool
    Is false if the option could not be added or removed.
    Zone string
    Name string
    The name of the option.
    OptionId string
    Id string
    The provider-assigned unique ID for this managed resource.
    Manageable bool
    Is false if the option could not be added or removed.
    Zone string
    Name string
    The name of the option.
    OptionId string
    id String
    The provider-assigned unique ID for this managed resource.
    manageable Boolean
    Is false if the option could not be added or removed.
    zone String
    name String
    The name of the option.
    optionId String
    id string
    The provider-assigned unique ID for this managed resource.
    manageable boolean
    Is false if the option could not be added or removed.
    zone string
    name string
    The name of the option.
    optionId string
    id str
    The provider-assigned unique ID for this managed resource.
    manageable bool
    Is false if the option could not be added or removed.
    zone str
    name str
    The name of the option.
    option_id str
    id String
    The provider-assigned unique ID for this managed resource.
    manageable Boolean
    Is false if the option could not be added or removed.
    zone String
    name String
    The name of the option.
    optionId String

    Package Details

    Repository
    scaleway pulumiverse/pulumi-scaleway
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the scaleway Terraform Provider.
    scaleway logo
    Scaleway v1.20.0 published on Monday, Nov 4, 2024 by pulumiverse