1. Packages
  2. OVH
  3. API Docs
  4. getServer
OVHCloud v2.0.7 published on Wednesday, Mar 19, 2025 by OVHcloud

ovh.getServer

Explore with Pulumi AI

OVHCloud v2.0.7 published on Wednesday, Mar 19, 2025 by OVHcloud

Use this data source to retrieve information about a dedicated server associated with your OVHcloud Account.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as ovh from "@pulumi/ovh";

const server = ovh.getServer({
    serviceName: "XXXXXX",
});
Copy
import pulumi
import pulumi_ovh as ovh

server = ovh.get_server(service_name="XXXXXX")
Copy
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := ovh.GetServer(ctx, &ovh.GetServerArgs{
			ServiceName: "XXXXXX",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ovh = Pulumi.Ovh;

return await Deployment.RunAsync(() => 
{
    var server = Ovh.GetServer.Invoke(new()
    {
        ServiceName = "XXXXXX",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ovh.OvhFunctions;
import com.pulumi.ovh.inputs.GetServerArgs;
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 server = OvhFunctions.getServer(GetServerArgs.builder()
            .serviceName("XXXXXX")
            .build());

    }
}
Copy
variables:
  server:
    fn::invoke:
      function: ovh:getServer
      arguments:
        serviceName: XXXXXX
Copy

Using getServer

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 getServer(args: GetServerArgs, opts?: InvokeOptions): Promise<GetServerResult>
function getServerOutput(args: GetServerOutputArgs, opts?: InvokeOptions): Output<GetServerResult>
Copy
def get_server(service_name: Optional[str] = None,
               opts: Optional[InvokeOptions] = None) -> GetServerResult
def get_server_output(service_name: Optional[pulumi.Input[str]] = None,
               opts: Optional[InvokeOptions] = None) -> Output[GetServerResult]
Copy
func GetServer(ctx *Context, args *GetServerArgs, opts ...InvokeOption) (*GetServerResult, error)
func GetServerOutput(ctx *Context, args *GetServerOutputArgs, opts ...InvokeOption) GetServerResultOutput
Copy

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

public static class GetServer 
{
    public static Task<GetServerResult> InvokeAsync(GetServerArgs args, InvokeOptions? opts = null)
    public static Output<GetServerResult> Invoke(GetServerInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetServerResult> getServer(GetServerArgs args, InvokeOptions options)
public static Output<GetServerResult> getServer(GetServerArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: ovh:index/getServer:getServer
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

ServiceName This property is required. string
The service_name of your dedicated server.
ServiceName This property is required. string
The service_name of your dedicated server.
serviceName This property is required. String
The service_name of your dedicated server.
serviceName This property is required. string
The service_name of your dedicated server.
service_name This property is required. str
The service_name of your dedicated server.
serviceName This property is required. String
The service_name of your dedicated server.

getServer Result

The following output properties are available:

AvailabilityZone string
Dedicated AZ localisation
BootId int
Boot id of the server
BootScript string
Boot script of the server
CommercialRange string
Dedicated server commercial range
Datacenter string
Dedicated datacenter localisation (bhs1,bhs2,...)
DisplayName string
Dedicated server display name
EfiBootloaderPath string
Path of the EFI bootloader of the dedicated server
EnabledPublicVnis List<string>
List of enabled public VNI uuids
EnabledVrackAggregationVnis List<string>
List of enabled vrack_aggregation VNI uuids
EnabledVrackVnis List<string>
List of enabled vrack VNI uuids
Id string
The provider-assigned unique ID for this managed resource.
Ip string
Dedicated server ip (IPv4)
Ips List<string>
Dedicated server ip blocks
LinkSpeed int
Link speed of the server
Monitoring bool
Icmp monitoring state
Name string
User defined VirtualNetworkInterface name
NewUpgradeSystem bool
NoIntervention bool
Prevent datacenter intervention
Os string
Operating system
PowerState string
Power state of the server (poweroff, poweron)
ProfessionalUse bool
Does this server have professional use option
Rack string
Rack id of the server
Region string
Dedicated region localisation
RescueMail string
Rescue mail of the server
RescueSshKey string
Public SSH Key used in the rescue mode
Reverse string
Dedicated server reverse
RootDevice string
Root device of the server
ServerId int
Server id
ServerURN string
URN of the dedicated server instance
ServiceName string
State string
Error, hacked, hackedBlocked, ok
SupportLevel string
Dedicated server support level (critical, fastpath, gs, pro)
Vnis List<GetServerVni>
The list of Virtualnetworkinterface associated with this server
AvailabilityZone string
Dedicated AZ localisation
BootId int
Boot id of the server
BootScript string
Boot script of the server
CommercialRange string
Dedicated server commercial range
Datacenter string
Dedicated datacenter localisation (bhs1,bhs2,...)
DisplayName string
Dedicated server display name
EfiBootloaderPath string
Path of the EFI bootloader of the dedicated server
EnabledPublicVnis []string
List of enabled public VNI uuids
EnabledVrackAggregationVnis []string
List of enabled vrack_aggregation VNI uuids
EnabledVrackVnis []string
List of enabled vrack VNI uuids
Id string
The provider-assigned unique ID for this managed resource.
Ip string
Dedicated server ip (IPv4)
Ips []string
Dedicated server ip blocks
LinkSpeed int
Link speed of the server
Monitoring bool
Icmp monitoring state
Name string
User defined VirtualNetworkInterface name
NewUpgradeSystem bool
NoIntervention bool
Prevent datacenter intervention
Os string
Operating system
PowerState string
Power state of the server (poweroff, poweron)
ProfessionalUse bool
Does this server have professional use option
Rack string
Rack id of the server
Region string
Dedicated region localisation
RescueMail string
Rescue mail of the server
RescueSshKey string
Public SSH Key used in the rescue mode
Reverse string
Dedicated server reverse
RootDevice string
Root device of the server
ServerId int
Server id
ServerURN string
URN of the dedicated server instance
ServiceName string
State string
Error, hacked, hackedBlocked, ok
SupportLevel string
Dedicated server support level (critical, fastpath, gs, pro)
Vnis []GetServerVni
The list of Virtualnetworkinterface associated with this server
ServerURN String
URN of the dedicated server instance
availabilityZone String
Dedicated AZ localisation
bootId Integer
Boot id of the server
bootScript String
Boot script of the server
commercialRange String
Dedicated server commercial range
datacenter String
Dedicated datacenter localisation (bhs1,bhs2,...)
displayName String
Dedicated server display name
efiBootloaderPath String
Path of the EFI bootloader of the dedicated server
enabledPublicVnis List<String>
List of enabled public VNI uuids
enabledVrackAggregationVnis List<String>
List of enabled vrack_aggregation VNI uuids
enabledVrackVnis List<String>
List of enabled vrack VNI uuids
id String
The provider-assigned unique ID for this managed resource.
ip String
Dedicated server ip (IPv4)
ips List<String>
Dedicated server ip blocks
linkSpeed Integer
Link speed of the server
monitoring Boolean
Icmp monitoring state
name String
User defined VirtualNetworkInterface name
newUpgradeSystem Boolean
noIntervention Boolean
Prevent datacenter intervention
os String
Operating system
powerState String
Power state of the server (poweroff, poweron)
professionalUse Boolean
Does this server have professional use option
rack String
Rack id of the server
region String
Dedicated region localisation
rescueMail String
Rescue mail of the server
rescueSshKey String
Public SSH Key used in the rescue mode
reverse String
Dedicated server reverse
rootDevice String
Root device of the server
serverId Integer
Server id
serviceName String
state String
Error, hacked, hackedBlocked, ok
supportLevel String
Dedicated server support level (critical, fastpath, gs, pro)
vnis List<GetServerVni>
The list of Virtualnetworkinterface associated with this server
ServerURN string
URN of the dedicated server instance
availabilityZone string
Dedicated AZ localisation
bootId number
Boot id of the server
bootScript string
Boot script of the server
commercialRange string
Dedicated server commercial range
datacenter string
Dedicated datacenter localisation (bhs1,bhs2,...)
displayName string
Dedicated server display name
efiBootloaderPath string
Path of the EFI bootloader of the dedicated server
enabledPublicVnis string[]
List of enabled public VNI uuids
enabledVrackAggregationVnis string[]
List of enabled vrack_aggregation VNI uuids
enabledVrackVnis string[]
List of enabled vrack VNI uuids
id string
The provider-assigned unique ID for this managed resource.
ip string
Dedicated server ip (IPv4)
ips string[]
Dedicated server ip blocks
linkSpeed number
Link speed of the server
monitoring boolean
Icmp monitoring state
name string
User defined VirtualNetworkInterface name
newUpgradeSystem boolean
noIntervention boolean
Prevent datacenter intervention
os string
Operating system
powerState string
Power state of the server (poweroff, poweron)
professionalUse boolean
Does this server have professional use option
rack string
Rack id of the server
region string
Dedicated region localisation
rescueMail string
Rescue mail of the server
rescueSshKey string
Public SSH Key used in the rescue mode
reverse string
Dedicated server reverse
rootDevice string
Root device of the server
serverId number
Server id
serviceName string
state string
Error, hacked, hackedBlocked, ok
supportLevel string
Dedicated server support level (critical, fastpath, gs, pro)
vnis GetServerVni[]
The list of Virtualnetworkinterface associated with this server
availability_zone str
Dedicated AZ localisation
boot_id int
Boot id of the server
boot_script str
Boot script of the server
commercial_range str
Dedicated server commercial range
datacenter str
Dedicated datacenter localisation (bhs1,bhs2,...)
display_name str
Dedicated server display name
efi_bootloader_path str
Path of the EFI bootloader of the dedicated server
enabled_public_vnis Sequence[str]
List of enabled public VNI uuids
enabled_vrack_aggregation_vnis Sequence[str]
List of enabled vrack_aggregation VNI uuids
enabled_vrack_vnis Sequence[str]
List of enabled vrack VNI uuids
id str
The provider-assigned unique ID for this managed resource.
ip str
Dedicated server ip (IPv4)
ips Sequence[str]
Dedicated server ip blocks
link_speed int
Link speed of the server
monitoring bool
Icmp monitoring state
name str
User defined VirtualNetworkInterface name
new_upgrade_system bool
no_intervention bool
Prevent datacenter intervention
os str
Operating system
power_state str
Power state of the server (poweroff, poweron)
professional_use bool
Does this server have professional use option
rack str
Rack id of the server
region str
Dedicated region localisation
rescue_mail str
Rescue mail of the server
rescue_ssh_key str
Public SSH Key used in the rescue mode
reverse str
Dedicated server reverse
root_device str
Root device of the server
server_id int
Server id
server_urn str
URN of the dedicated server instance
service_name str
state str
Error, hacked, hackedBlocked, ok
support_level str
Dedicated server support level (critical, fastpath, gs, pro)
vnis Sequence[GetServerVni]
The list of Virtualnetworkinterface associated with this server
ServerURN String
URN of the dedicated server instance
availabilityZone String
Dedicated AZ localisation
bootId Number
Boot id of the server
bootScript String
Boot script of the server
commercialRange String
Dedicated server commercial range
datacenter String
Dedicated datacenter localisation (bhs1,bhs2,...)
displayName String
Dedicated server display name
efiBootloaderPath String
Path of the EFI bootloader of the dedicated server
enabledPublicVnis List<String>
List of enabled public VNI uuids
enabledVrackAggregationVnis List<String>
List of enabled vrack_aggregation VNI uuids
enabledVrackVnis List<String>
List of enabled vrack VNI uuids
id String
The provider-assigned unique ID for this managed resource.
ip String
Dedicated server ip (IPv4)
ips List<String>
Dedicated server ip blocks
linkSpeed Number
Link speed of the server
monitoring Boolean
Icmp monitoring state
name String
User defined VirtualNetworkInterface name
newUpgradeSystem Boolean
noIntervention Boolean
Prevent datacenter intervention
os String
Operating system
powerState String
Power state of the server (poweroff, poweron)
professionalUse Boolean
Does this server have professional use option
rack String
Rack id of the server
region String
Dedicated region localisation
rescueMail String
Rescue mail of the server
rescueSshKey String
Public SSH Key used in the rescue mode
reverse String
Dedicated server reverse
rootDevice String
Root device of the server
serverId Number
Server id
serviceName String
state String
Error, hacked, hackedBlocked, ok
supportLevel String
Dedicated server support level (critical, fastpath, gs, pro)
vnis List<Property Map>
The list of Virtualnetworkinterface associated with this server

Supporting Types

GetServerVni

Enabled This property is required. bool
VirtualNetworkInterface activation state
Mode This property is required. string
VirtualNetworkInterface mode (public,vrack,vrack_aggregation)
Name This property is required. string
User defined VirtualNetworkInterface name
Nics This property is required. List<string>
NetworkInterfaceControllers bound to this VirtualNetworkInterface
ServerName This property is required. string
Server bound to this VirtualNetworkInterface
Uuid This property is required. string
VirtualNetworkInterface unique id
Vrack This property is required. string
vRack name
Enabled This property is required. bool
VirtualNetworkInterface activation state
Mode This property is required. string
VirtualNetworkInterface mode (public,vrack,vrack_aggregation)
Name This property is required. string
User defined VirtualNetworkInterface name
Nics This property is required. []string
NetworkInterfaceControllers bound to this VirtualNetworkInterface
ServerName This property is required. string
Server bound to this VirtualNetworkInterface
Uuid This property is required. string
VirtualNetworkInterface unique id
Vrack This property is required. string
vRack name
enabled This property is required. Boolean
VirtualNetworkInterface activation state
mode This property is required. String
VirtualNetworkInterface mode (public,vrack,vrack_aggregation)
name This property is required. String
User defined VirtualNetworkInterface name
nics This property is required. List<String>
NetworkInterfaceControllers bound to this VirtualNetworkInterface
serverName This property is required. String
Server bound to this VirtualNetworkInterface
uuid This property is required. String
VirtualNetworkInterface unique id
vrack This property is required. String
vRack name
enabled This property is required. boolean
VirtualNetworkInterface activation state
mode This property is required. string
VirtualNetworkInterface mode (public,vrack,vrack_aggregation)
name This property is required. string
User defined VirtualNetworkInterface name
nics This property is required. string[]
NetworkInterfaceControllers bound to this VirtualNetworkInterface
serverName This property is required. string
Server bound to this VirtualNetworkInterface
uuid This property is required. string
VirtualNetworkInterface unique id
vrack This property is required. string
vRack name
enabled This property is required. bool
VirtualNetworkInterface activation state
mode This property is required. str
VirtualNetworkInterface mode (public,vrack,vrack_aggregation)
name This property is required. str
User defined VirtualNetworkInterface name
nics This property is required. Sequence[str]
NetworkInterfaceControllers bound to this VirtualNetworkInterface
server_name This property is required. str
Server bound to this VirtualNetworkInterface
uuid This property is required. str
VirtualNetworkInterface unique id
vrack This property is required. str
vRack name
enabled This property is required. Boolean
VirtualNetworkInterface activation state
mode This property is required. String
VirtualNetworkInterface mode (public,vrack,vrack_aggregation)
name This property is required. String
User defined VirtualNetworkInterface name
nics This property is required. List<String>
NetworkInterfaceControllers bound to this VirtualNetworkInterface
serverName This property is required. String
Server bound to this VirtualNetworkInterface
uuid This property is required. String
VirtualNetworkInterface unique id
vrack This property is required. String
vRack name

Package Details

Repository
ovh ovh/pulumi-ovh
License
Apache-2.0
Notes
This Pulumi package is based on the ovh Terraform Provider.
OVHCloud v2.0.7 published on Wednesday, Mar 19, 2025 by OVHcloud