1. Packages
  2. Scaleway
  3. API Docs
  4. getInstanceVolume
Scaleway v1.10.0 published on Saturday, Jul 1, 2023 by lbrlabs

scaleway.getInstanceVolume

Explore with Pulumi AI

scaleway logo
Scaleway v1.10.0 published on Saturday, Jul 1, 2023 by lbrlabs

    Gets information about an instance volume.

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Scaleway = Pulumi.Scaleway;
    
    return await Deployment.RunAsync(() => 
    {
        var myVolume = Scaleway.GetInstanceVolume.Invoke(new()
        {
            VolumeId = "11111111-1111-1111-1111-111111111111",
        });
    
    });
    
    package main
    
    import (
    	"github.com/lbrlabs/pulumi-scaleway/sdk/go/scaleway"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := scaleway.LookupInstanceVolume(ctx, &scaleway.LookupInstanceVolumeArgs{
    			VolumeId: pulumi.StringRef("11111111-1111-1111-1111-111111111111"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    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.GetInstanceVolumeArgs;
    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 myVolume = ScalewayFunctions.getInstanceVolume(GetInstanceVolumeArgs.builder()
                .volumeId("11111111-1111-1111-1111-111111111111")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_scaleway as scaleway
    
    my_volume = scaleway.get_instance_volume(volume_id="11111111-1111-1111-1111-111111111111")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as scaleway from "@pulumi/scaleway";
    
    const myVolume = scaleway.getInstanceVolume({
        volumeId: "11111111-1111-1111-1111-111111111111",
    });
    
    variables:
      myVolume:
        fn::invoke:
          Function: scaleway:getInstanceVolume
          Arguments:
            volumeId: 11111111-1111-1111-1111-111111111111
    

    Using getInstanceVolume

    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 getInstanceVolume(args: GetInstanceVolumeArgs, opts?: InvokeOptions): Promise<GetInstanceVolumeResult>
    function getInstanceVolumeOutput(args: GetInstanceVolumeOutputArgs, opts?: InvokeOptions): Output<GetInstanceVolumeResult>
    def get_instance_volume(name: Optional[str] = None,
                            volume_id: Optional[str] = None,
                            zone: Optional[str] = None,
                            opts: Optional[InvokeOptions] = None) -> GetInstanceVolumeResult
    def get_instance_volume_output(name: Optional[pulumi.Input[str]] = None,
                            volume_id: Optional[pulumi.Input[str]] = None,
                            zone: Optional[pulumi.Input[str]] = None,
                            opts: Optional[InvokeOptions] = None) -> Output[GetInstanceVolumeResult]
    func LookupInstanceVolume(ctx *Context, args *LookupInstanceVolumeArgs, opts ...InvokeOption) (*LookupInstanceVolumeResult, error)
    func LookupInstanceVolumeOutput(ctx *Context, args *LookupInstanceVolumeOutputArgs, opts ...InvokeOption) LookupInstanceVolumeResultOutput

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

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

    The following arguments are supported:

    Name string

    The volume name. Only one of name and volume_id should be specified.

    VolumeId string

    The volume id. Only one of name and volume_id should be specified.

    Zone string

    zone) The zone in which the volume exists.

    Name string

    The volume name. Only one of name and volume_id should be specified.

    VolumeId string

    The volume id. Only one of name and volume_id should be specified.

    Zone string

    zone) The zone in which the volume exists.

    name String

    The volume name. Only one of name and volume_id should be specified.

    volumeId String

    The volume id. Only one of name and volume_id should be specified.

    zone String

    zone) The zone in which the volume exists.

    name string

    The volume name. Only one of name and volume_id should be specified.

    volumeId string

    The volume id. Only one of name and volume_id should be specified.

    zone string

    zone) The zone in which the volume exists.

    name str

    The volume name. Only one of name and volume_id should be specified.

    volume_id str

    The volume id. Only one of name and volume_id should be specified.

    zone str

    zone) The zone in which the volume exists.

    name String

    The volume name. Only one of name and volume_id should be specified.

    volumeId String

    The volume id. Only one of name and volume_id should be specified.

    zone String

    zone) The zone in which the volume exists.

    getInstanceVolume Result

    The following output properties are available:

    FromSnapshotId string
    FromVolumeId string
    Id string

    The provider-assigned unique ID for this managed resource.

    OrganizationId string

    The ID of the organization the volume is associated with.

    ProjectId string
    ServerId string
    SizeInGb int
    Tags List<string>
    Type string
    Name string
    VolumeId string
    Zone string
    FromSnapshotId string
    FromVolumeId string
    Id string

    The provider-assigned unique ID for this managed resource.

    OrganizationId string

    The ID of the organization the volume is associated with.

    ProjectId string
    ServerId string
    SizeInGb int
    Tags []string
    Type string
    Name string
    VolumeId string
    Zone string
    fromSnapshotId String
    fromVolumeId String
    id String

    The provider-assigned unique ID for this managed resource.

    organizationId String

    The ID of the organization the volume is associated with.

    projectId String
    serverId String
    sizeInGb Integer
    tags List<String>
    type String
    name String
    volumeId String
    zone String
    fromSnapshotId string
    fromVolumeId string
    id string

    The provider-assigned unique ID for this managed resource.

    organizationId string

    The ID of the organization the volume is associated with.

    projectId string
    serverId string
    sizeInGb number
    tags string[]
    type string
    name string
    volumeId string
    zone string
    from_snapshot_id str
    from_volume_id str
    id str

    The provider-assigned unique ID for this managed resource.

    organization_id str

    The ID of the organization the volume is associated with.

    project_id str
    server_id str
    size_in_gb int
    tags Sequence[str]
    type str
    name str
    volume_id str
    zone str
    fromSnapshotId String
    fromVolumeId String
    id String

    The provider-assigned unique ID for this managed resource.

    organizationId String

    The ID of the organization the volume is associated with.

    projectId String
    serverId String
    sizeInGb Number
    tags List<String>
    type String
    name String
    volumeId String
    zone String

    Package Details

    Repository
    scaleway lbrlabs/pulumi-scaleway
    License
    Apache-2.0
    Notes

    This Pulumi package is based on the scaleway Terraform Provider.

    scaleway logo
    Scaleway v1.10.0 published on Saturday, Jul 1, 2023 by lbrlabs