ibm.ComputeDedicatedHost
Explore with Pulumi AI
Create, update, and delete a dedicated host resource. For more information, about compute dedicated host, see dedicated hosts and dedicated instances.
Note For more information, see SoftLayer API docs.
Example Usage
In the following example, you can create a dedicated host:
import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";
const dedicatedhost = new ibm.ComputeDedicatedHost("dedicatedhost", {
datacenter: "dal09",
domain: "example.com",
hostname: "host",
routerHostname: "bcr01a.dal09",
});
import pulumi
import pulumi_ibm as ibm
dedicatedhost = ibm.ComputeDedicatedHost("dedicatedhost",
datacenter="dal09",
domain="example.com",
hostname="host",
router_hostname="bcr01a.dal09")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ibm.NewComputeDedicatedHost(ctx, "dedicatedhost", &ibm.ComputeDedicatedHostArgs{
Datacenter: pulumi.String("dal09"),
Domain: pulumi.String("example.com"),
Hostname: pulumi.String("host"),
RouterHostname: pulumi.String("bcr01a.dal09"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ibm = Pulumi.Ibm;
return await Deployment.RunAsync(() =>
{
var dedicatedhost = new Ibm.ComputeDedicatedHost("dedicatedhost", new()
{
Datacenter = "dal09",
Domain = "example.com",
Hostname = "host",
RouterHostname = "bcr01a.dal09",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ibm.ComputeDedicatedHost;
import com.pulumi.ibm.ComputeDedicatedHostArgs;
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) {
var dedicatedhost = new ComputeDedicatedHost("dedicatedhost", ComputeDedicatedHostArgs.builder()
.datacenter("dal09")
.domain("example.com")
.hostname("host")
.routerHostname("bcr01a.dal09")
.build());
}
}
resources:
dedicatedhost:
type: ibm:ComputeDedicatedHost
properties:
datacenter: dal09
domain: example.com
hostname: host
routerHostname: bcr01a.dal09
Create ComputeDedicatedHost Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ComputeDedicatedHost(name: string, args: ComputeDedicatedHostArgs, opts?: CustomResourceOptions);
@overload
def ComputeDedicatedHost(resource_name: str,
args: ComputeDedicatedHostArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ComputeDedicatedHost(resource_name: str,
opts: Optional[ResourceOptions] = None,
datacenter: Optional[str] = None,
domain: Optional[str] = None,
hostname: Optional[str] = None,
router_hostname: Optional[str] = None,
compute_dedicated_host_id: Optional[str] = None,
flavor: Optional[str] = None,
hourly_billing: Optional[bool] = None,
tags: Optional[Sequence[str]] = None,
wait_time_minutes: Optional[float] = None)
func NewComputeDedicatedHost(ctx *Context, name string, args ComputeDedicatedHostArgs, opts ...ResourceOption) (*ComputeDedicatedHost, error)
public ComputeDedicatedHost(string name, ComputeDedicatedHostArgs args, CustomResourceOptions? opts = null)
public ComputeDedicatedHost(String name, ComputeDedicatedHostArgs args)
public ComputeDedicatedHost(String name, ComputeDedicatedHostArgs args, CustomResourceOptions options)
type: ibm:ComputeDedicatedHost
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ComputeDedicatedHostArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ComputeDedicatedHostArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ComputeDedicatedHostArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ComputeDedicatedHostArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ComputeDedicatedHostArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var computeDedicatedHostResource = new Ibm.ComputeDedicatedHost("computeDedicatedHostResource", new()
{
Datacenter = "string",
Domain = "string",
Hostname = "string",
RouterHostname = "string",
ComputeDedicatedHostId = "string",
Flavor = "string",
HourlyBilling = false,
Tags = new[]
{
"string",
},
WaitTimeMinutes = 0,
});
example, err := ibm.NewComputeDedicatedHost(ctx, "computeDedicatedHostResource", &ibm.ComputeDedicatedHostArgs{
Datacenter: pulumi.String("string"),
Domain: pulumi.String("string"),
Hostname: pulumi.String("string"),
RouterHostname: pulumi.String("string"),
ComputeDedicatedHostId: pulumi.String("string"),
Flavor: pulumi.String("string"),
HourlyBilling: pulumi.Bool(false),
Tags: pulumi.StringArray{
pulumi.String("string"),
},
WaitTimeMinutes: pulumi.Float64(0),
})
var computeDedicatedHostResource = new ComputeDedicatedHost("computeDedicatedHostResource", ComputeDedicatedHostArgs.builder()
.datacenter("string")
.domain("string")
.hostname("string")
.routerHostname("string")
.computeDedicatedHostId("string")
.flavor("string")
.hourlyBilling(false)
.tags("string")
.waitTimeMinutes(0)
.build());
compute_dedicated_host_resource = ibm.ComputeDedicatedHost("computeDedicatedHostResource",
datacenter="string",
domain="string",
hostname="string",
router_hostname="string",
compute_dedicated_host_id="string",
flavor="string",
hourly_billing=False,
tags=["string"],
wait_time_minutes=0)
const computeDedicatedHostResource = new ibm.ComputeDedicatedHost("computeDedicatedHostResource", {
datacenter: "string",
domain: "string",
hostname: "string",
routerHostname: "string",
computeDedicatedHostId: "string",
flavor: "string",
hourlyBilling: false,
tags: ["string"],
waitTimeMinutes: 0,
});
type: ibm:ComputeDedicatedHost
properties:
computeDedicatedHostId: string
datacenter: string
domain: string
flavor: string
hostname: string
hourlyBilling: false
routerHostname: string
tags:
- string
waitTimeMinutes: 0
ComputeDedicatedHost Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The ComputeDedicatedHost resource accepts the following input properties:
- Datacenter string
- The data center in which the dedicated host resides.
- Domain string
- The domain of dedicated host.
- Hostname string
- The host name of dedicated host.
- Router
Hostname string - The hostname of the primary router associated with the dedicated host.
- Compute
Dedicated stringHost Id - (String) The unique identifier of the dedicated host.
- Flavor string
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - Hourly
Billing bool - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- List<string>
- Tags associated with the dedicated host.
- Wait
Time doubleMinutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- Datacenter string
- The data center in which the dedicated host resides.
- Domain string
- The domain of dedicated host.
- Hostname string
- The host name of dedicated host.
- Router
Hostname string - The hostname of the primary router associated with the dedicated host.
- Compute
Dedicated stringHost Id - (String) The unique identifier of the dedicated host.
- Flavor string
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - Hourly
Billing bool - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- []string
- Tags associated with the dedicated host.
- Wait
Time float64Minutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- datacenter String
- The data center in which the dedicated host resides.
- domain String
- The domain of dedicated host.
- hostname String
- The host name of dedicated host.
- router
Hostname String - The hostname of the primary router associated with the dedicated host.
- compute
Dedicated StringHost Id - (String) The unique identifier of the dedicated host.
- flavor String
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - hourly
Billing Boolean - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- List<String>
- Tags associated with the dedicated host.
- wait
Time DoubleMinutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- datacenter string
- The data center in which the dedicated host resides.
- domain string
- The domain of dedicated host.
- hostname string
- The host name of dedicated host.
- router
Hostname string - The hostname of the primary router associated with the dedicated host.
- compute
Dedicated stringHost Id - (String) The unique identifier of the dedicated host.
- flavor string
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - hourly
Billing boolean - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- string[]
- Tags associated with the dedicated host.
- wait
Time numberMinutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- datacenter str
- The data center in which the dedicated host resides.
- domain str
- The domain of dedicated host.
- hostname str
- The host name of dedicated host.
- router_
hostname str - The hostname of the primary router associated with the dedicated host.
- compute_
dedicated_ strhost_ id - (String) The unique identifier of the dedicated host.
- flavor str
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - hourly_
billing bool - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- Sequence[str]
- Tags associated with the dedicated host.
- wait_
time_ floatminutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- datacenter String
- The data center in which the dedicated host resides.
- domain String
- The domain of dedicated host.
- hostname String
- The host name of dedicated host.
- router
Hostname String - The hostname of the primary router associated with the dedicated host.
- compute
Dedicated StringHost Id - (String) The unique identifier of the dedicated host.
- flavor String
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - hourly
Billing Boolean - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- List<String>
- Tags associated with the dedicated host.
- wait
Time NumberMinutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
Outputs
All input properties are implicitly available as output properties. Additionally, the ComputeDedicatedHost resource produces the following output properties:
- Cpu
Count double - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- Disk
Capacity double - (String) The capacity that the dedicated host's disk allocation is restricted to.
- Id string
- The provider-assigned unique ID for this managed resource.
- Memory
Capacity double - (String) The capacity that the dedicated host's memory allocation is restricted to.
- Cpu
Count float64 - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- Disk
Capacity float64 - (String) The capacity that the dedicated host's disk allocation is restricted to.
- Id string
- The provider-assigned unique ID for this managed resource.
- Memory
Capacity float64 - (String) The capacity that the dedicated host's memory allocation is restricted to.
- cpu
Count Double - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- disk
Capacity Double - (String) The capacity that the dedicated host's disk allocation is restricted to.
- id String
- The provider-assigned unique ID for this managed resource.
- memory
Capacity Double - (String) The capacity that the dedicated host's memory allocation is restricted to.
- cpu
Count number - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- disk
Capacity number - (String) The capacity that the dedicated host's disk allocation is restricted to.
- id string
- The provider-assigned unique ID for this managed resource.
- memory
Capacity number - (String) The capacity that the dedicated host's memory allocation is restricted to.
- cpu_
count float - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- disk_
capacity float - (String) The capacity that the dedicated host's disk allocation is restricted to.
- id str
- The provider-assigned unique ID for this managed resource.
- memory_
capacity float - (String) The capacity that the dedicated host's memory allocation is restricted to.
- cpu
Count Number - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- disk
Capacity Number - (String) The capacity that the dedicated host's disk allocation is restricted to.
- id String
- The provider-assigned unique ID for this managed resource.
- memory
Capacity Number - (String) The capacity that the dedicated host's memory allocation is restricted to.
Look up Existing ComputeDedicatedHost Resource
Get an existing ComputeDedicatedHost resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: ComputeDedicatedHostState, opts?: CustomResourceOptions): ComputeDedicatedHost
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
compute_dedicated_host_id: Optional[str] = None,
cpu_count: Optional[float] = None,
datacenter: Optional[str] = None,
disk_capacity: Optional[float] = None,
domain: Optional[str] = None,
flavor: Optional[str] = None,
hostname: Optional[str] = None,
hourly_billing: Optional[bool] = None,
memory_capacity: Optional[float] = None,
router_hostname: Optional[str] = None,
tags: Optional[Sequence[str]] = None,
wait_time_minutes: Optional[float] = None) -> ComputeDedicatedHost
func GetComputeDedicatedHost(ctx *Context, name string, id IDInput, state *ComputeDedicatedHostState, opts ...ResourceOption) (*ComputeDedicatedHost, error)
public static ComputeDedicatedHost Get(string name, Input<string> id, ComputeDedicatedHostState? state, CustomResourceOptions? opts = null)
public static ComputeDedicatedHost get(String name, Output<String> id, ComputeDedicatedHostState state, CustomResourceOptions options)
resources: _: type: ibm:ComputeDedicatedHost get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Compute
Dedicated stringHost Id - (String) The unique identifier of the dedicated host.
- Cpu
Count double - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- Datacenter string
- The data center in which the dedicated host resides.
- Disk
Capacity double - (String) The capacity that the dedicated host's disk allocation is restricted to.
- Domain string
- The domain of dedicated host.
- Flavor string
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - Hostname string
- The host name of dedicated host.
- Hourly
Billing bool - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- Memory
Capacity double - (String) The capacity that the dedicated host's memory allocation is restricted to.
- Router
Hostname string - The hostname of the primary router associated with the dedicated host.
- List<string>
- Tags associated with the dedicated host.
- Wait
Time doubleMinutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- Compute
Dedicated stringHost Id - (String) The unique identifier of the dedicated host.
- Cpu
Count float64 - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- Datacenter string
- The data center in which the dedicated host resides.
- Disk
Capacity float64 - (String) The capacity that the dedicated host's disk allocation is restricted to.
- Domain string
- The domain of dedicated host.
- Flavor string
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - Hostname string
- The host name of dedicated host.
- Hourly
Billing bool - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- Memory
Capacity float64 - (String) The capacity that the dedicated host's memory allocation is restricted to.
- Router
Hostname string - The hostname of the primary router associated with the dedicated host.
- []string
- Tags associated with the dedicated host.
- Wait
Time float64Minutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- compute
Dedicated StringHost Id - (String) The unique identifier of the dedicated host.
- cpu
Count Double - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- datacenter String
- The data center in which the dedicated host resides.
- disk
Capacity Double - (String) The capacity that the dedicated host's disk allocation is restricted to.
- domain String
- The domain of dedicated host.
- flavor String
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - hostname String
- The host name of dedicated host.
- hourly
Billing Boolean - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- memory
Capacity Double - (String) The capacity that the dedicated host's memory allocation is restricted to.
- router
Hostname String - The hostname of the primary router associated with the dedicated host.
- List<String>
- Tags associated with the dedicated host.
- wait
Time DoubleMinutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- compute
Dedicated stringHost Id - (String) The unique identifier of the dedicated host.
- cpu
Count number - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- datacenter string
- The data center in which the dedicated host resides.
- disk
Capacity number - (String) The capacity that the dedicated host's disk allocation is restricted to.
- domain string
- The domain of dedicated host.
- flavor string
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - hostname string
- The host name of dedicated host.
- hourly
Billing boolean - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- memory
Capacity number - (String) The capacity that the dedicated host's memory allocation is restricted to.
- router
Hostname string - The hostname of the primary router associated with the dedicated host.
- string[]
- Tags associated with the dedicated host.
- wait
Time numberMinutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- compute_
dedicated_ strhost_ id - (String) The unique identifier of the dedicated host.
- cpu_
count float - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- datacenter str
- The data center in which the dedicated host resides.
- disk_
capacity float - (String) The capacity that the dedicated host's disk allocation is restricted to.
- domain str
- The domain of dedicated host.
- flavor str
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - hostname str
- The host name of dedicated host.
- hourly_
billing bool - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- memory_
capacity float - (String) The capacity that the dedicated host's memory allocation is restricted to.
- router_
hostname str - The hostname of the primary router associated with the dedicated host.
- Sequence[str]
- Tags associated with the dedicated host.
- wait_
time_ floatminutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
- compute
Dedicated StringHost Id - (String) The unique identifier of the dedicated host.
- cpu
Count Number - (String) The capacity that the dedicated host's CPU allocation is restricted to.
- datacenter String
- The data center in which the dedicated host resides.
- disk
Capacity Number - (String) The capacity that the dedicated host's disk allocation is restricted to.
- domain String
- The domain of dedicated host.
- flavor String
- The flavor of dedicated host. Default value
56_CORES_X_242_RAM_X_1_4_TB
. Log in to the IBM-Cloud Infrastructure API to see available flavor types. Use your API as the password to log in. Log in and find the key calledkeyName
. - hostname String
- The host name of dedicated host.
- hourly
Billing Boolean - The billing type for the host. When set to true, the dedicated host is billed on hourly usage. Otherwise, the dedicated host is billed monthly. The default value is true.
- memory
Capacity Number - (String) The capacity that the dedicated host's memory allocation is restricted to.
- router
Hostname String - The hostname of the primary router associated with the dedicated host.
- List<String>
- Tags associated with the dedicated host.
- wait
Time NumberMinutes - The duration, expressed in minutes to wait for the dedicated host to become available before creation. The default value is
90
.
Import
The ibm_compute_dedicated_host
resource can be imported by using the ID.
Example
$ pulumi import ibm:index/computeDedicatedHost:ComputeDedicatedHost dedicatedhost 238756
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- ibm ibm-cloud/terraform-provider-ibm
- License
- Notes
- This Pulumi package is based on the
ibm
Terraform Provider.