Viewing docs for OVHCloud v2.12.0
published on Thursday, Mar 12, 2026 by OVHcloud
published on Thursday, Mar 12, 2026 by OVHcloud
Viewing docs for OVHCloud v2.12.0
published on Thursday, Mar 12, 2026 by OVHcloud
published on Thursday, Mar 12, 2026 by OVHcloud
Get information about a volume in a public cloud project
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ovh from "@ovhcloud/pulumi-ovh";
const volume = ovh.CloudProject.getVolume({
regionName: "xxx",
serviceName: "yyy",
volumeId: "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
});
import pulumi
import pulumi_ovh as ovh
volume = ovh.CloudProject.get_volume(region_name="xxx",
service_name="yyy",
volume_id="aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee")
package main
import (
"github.com/ovh/pulumi-ovh/sdk/v2/go/ovh/cloudproject"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cloudproject.GetVolume(ctx, &cloudproject.GetVolumeArgs{
RegionName: "xxx",
ServiceName: "yyy",
VolumeId: "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ovh = Pulumi.Ovh;
return await Deployment.RunAsync(() =>
{
var volume = Ovh.CloudProject.GetVolume.Invoke(new()
{
RegionName = "xxx",
ServiceName = "yyy",
VolumeId = "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ovh.CloudProject.CloudProjectFunctions;
import com.pulumi.ovh.CloudProject.inputs.GetVolumeArgs;
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 volume = CloudProjectFunctions.getVolume(GetVolumeArgs.builder()
.regionName("xxx")
.serviceName("yyy")
.volumeId("aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee")
.build());
}
}
variables:
volume:
fn::invoke:
function: ovh:CloudProject:getVolume
arguments:
regionName: xxx
serviceName: yyy
volumeId: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
Using getVolume
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 getVolume(args: GetVolumeArgs, opts?: InvokeOptions): Promise<GetVolumeResult>
function getVolumeOutput(args: GetVolumeOutputArgs, opts?: InvokeOptions): Output<GetVolumeResult>def get_volume(region_name: Optional[str] = None,
service_name: Optional[str] = None,
volume_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetVolumeResult
def get_volume_output(region_name: Optional[pulumi.Input[str]] = None,
service_name: Optional[pulumi.Input[str]] = None,
volume_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetVolumeResult]func LookupVolume(ctx *Context, args *LookupVolumeArgs, opts ...InvokeOption) (*LookupVolumeResult, error)
func LookupVolumeOutput(ctx *Context, args *LookupVolumeOutputArgs, opts ...InvokeOption) LookupVolumeResultOutput> Note: This function is named LookupVolume in the Go SDK.
public static class GetVolume
{
public static Task<GetVolumeResult> InvokeAsync(GetVolumeArgs args, InvokeOptions? opts = null)
public static Output<GetVolumeResult> Invoke(GetVolumeInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetVolumeResult> getVolume(GetVolumeArgs args, InvokeOptions options)
public static Output<GetVolumeResult> getVolume(GetVolumeArgs args, InvokeOptions options)
fn::invoke:
function: ovh:CloudProject/getVolume:getVolume
arguments:
# arguments dictionaryThe following arguments are supported:
- Region
Name string - A valid OVHcloud public cloud region name in which the volume is available. Ex.: "GRA11".
- Service
Name string - The id of the public cloud project.
- Volume
Id string - Volume id to get the informations
- Region
Name string - A valid OVHcloud public cloud region name in which the volume is available. Ex.: "GRA11".
- Service
Name string - The id of the public cloud project.
- Volume
Id string - Volume id to get the informations
- region
Name String - A valid OVHcloud public cloud region name in which the volume is available. Ex.: "GRA11".
- service
Name String - The id of the public cloud project.
- volume
Id String - Volume id to get the informations
- region
Name string - A valid OVHcloud public cloud region name in which the volume is available. Ex.: "GRA11".
- service
Name string - The id of the public cloud project.
- volume
Id string - Volume id to get the informations
- region_
name str - A valid OVHcloud public cloud region name in which the volume is available. Ex.: "GRA11".
- service_
name str - The id of the public cloud project.
- volume_
id str - Volume id to get the informations
- region
Name String - A valid OVHcloud public cloud region name in which the volume is available. Ex.: "GRA11".
- service
Name String - The id of the public cloud project.
- volume
Id String - Volume id to get the informations
getVolume Result
The following output properties are available:
- Id string
- Name string
- The name of the volume (E.g.: "GRA", meaning Gravelines, for region "GRA1")
- Region
Name string - The region name where volume is available
- Service
Name string - The id of the public cloud project.
- Size double
- The size of the volume
- Volume
Id string - The id of the volume
- Id string
- Name string
- The name of the volume (E.g.: "GRA", meaning Gravelines, for region "GRA1")
- Region
Name string - The region name where volume is available
- Service
Name string - The id of the public cloud project.
- Size float64
- The size of the volume
- Volume
Id string - The id of the volume
- id String
- name String
- The name of the volume (E.g.: "GRA", meaning Gravelines, for region "GRA1")
- region
Name String - The region name where volume is available
- service
Name String - The id of the public cloud project.
- size Double
- The size of the volume
- volume
Id String - The id of the volume
- id string
- name string
- The name of the volume (E.g.: "GRA", meaning Gravelines, for region "GRA1")
- region
Name string - The region name where volume is available
- service
Name string - The id of the public cloud project.
- size number
- The size of the volume
- volume
Id string - The id of the volume
- id str
- name str
- The name of the volume (E.g.: "GRA", meaning Gravelines, for region "GRA1")
- region_
name str - The region name where volume is available
- service_
name str - The id of the public cloud project.
- size float
- The size of the volume
- volume_
id str - The id of the volume
- id String
- name String
- The name of the volume (E.g.: "GRA", meaning Gravelines, for region "GRA1")
- region
Name String - The region name where volume is available
- service
Name String - The id of the public cloud project.
- size Number
- The size of the volume
- volume
Id String - The id of the volume
Package Details
- Repository
- ovh ovh/pulumi-ovh
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
ovhTerraform Provider.
Viewing docs for OVHCloud v2.12.0
published on Thursday, Mar 12, 2026 by OVHcloud
published on Thursday, Mar 12, 2026 by OVHcloud
