Cache
Manages a HPC Cache.
Note: During the first several months of the GA release, a request must be made to the Azure HPC Cache team to add your subscription to the access list before it can be used to create a cache instance. Fill out this form to request access.
Example Usage
using Pulumi;
using Azure = Pulumi.Azure;
class MyStack : Stack
{
public MyStack()
{
var exampleResourceGroup = new Azure.Core.ResourceGroup("exampleResourceGroup", new Azure.Core.ResourceGroupArgs
{
Location = "West Europe",
});
var exampleVirtualNetwork = new Azure.Network.VirtualNetwork("exampleVirtualNetwork", new Azure.Network.VirtualNetworkArgs
{
AddressSpaces =
{
"10.0.0.0/16",
},
Location = exampleResourceGroup.Location,
ResourceGroupName = exampleResourceGroup.Name,
});
var exampleSubnet = new Azure.Network.Subnet("exampleSubnet", new Azure.Network.SubnetArgs
{
ResourceGroupName = exampleResourceGroup.Name,
VirtualNetworkName = exampleVirtualNetwork.Name,
AddressPrefix = "10.0.1.0/24",
});
var exampleCache = new Azure.Hpc.Cache("exampleCache", new Azure.Hpc.CacheArgs
{
ResourceGroupName = exampleResourceGroup.Name,
Location = exampleResourceGroup.Location,
CacheSizeInGb = 3072,
SubnetId = exampleSubnet.Id,
SkuName = "Standard_2G",
});
}
}
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v3/go/azure/core"
"github.com/pulumi/pulumi-azure/sdk/v3/go/azure/hpc"
"github.com/pulumi/pulumi-azure/sdk/v3/go/azure/network"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleResourceGroup, err := core.NewResourceGroup(ctx, "exampleResourceGroup", &core.ResourceGroupArgs{
Location: pulumi.String("West Europe"),
})
if err != nil {
return err
}
exampleVirtualNetwork, err := network.NewVirtualNetwork(ctx, "exampleVirtualNetwork", &network.VirtualNetworkArgs{
AddressSpaces: pulumi.StringArray{
pulumi.String("10.0.0.0/16"),
},
Location: exampleResourceGroup.Location,
ResourceGroupName: exampleResourceGroup.Name,
})
if err != nil {
return err
}
exampleSubnet, err := network.NewSubnet(ctx, "exampleSubnet", &network.SubnetArgs{
ResourceGroupName: exampleResourceGroup.Name,
VirtualNetworkName: exampleVirtualNetwork.Name,
AddressPrefix: pulumi.String("10.0.1.0/24"),
})
if err != nil {
return err
}
_, err = hpc.NewCache(ctx, "exampleCache", &hpc.CacheArgs{
ResourceGroupName: exampleResourceGroup.Name,
Location: exampleResourceGroup.Location,
CacheSizeInGb: pulumi.Int(3072),
SubnetId: exampleSubnet.ID(),
SkuName: pulumi.String("Standard_2G"),
})
if err != nil {
return err
}
return nil
})
}import pulumi
import pulumi_azure as azure
example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe")
example_virtual_network = azure.network.VirtualNetwork("exampleVirtualNetwork",
address_spaces=["10.0.0.0/16"],
location=example_resource_group.location,
resource_group_name=example_resource_group.name)
example_subnet = azure.network.Subnet("exampleSubnet",
resource_group_name=example_resource_group.name,
virtual_network_name=example_virtual_network.name,
address_prefix="10.0.1.0/24")
example_cache = azure.hpc.Cache("exampleCache",
resource_group_name=example_resource_group.name,
location=example_resource_group.location,
cache_size_in_gb=3072,
subnet_id=example_subnet.id,
sku_name="Standard_2G")import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const exampleResourceGroup = new azure.core.ResourceGroup("exampleResourceGroup", {location: "West Europe"});
const exampleVirtualNetwork = new azure.network.VirtualNetwork("exampleVirtualNetwork", {
addressSpaces: ["10.0.0.0/16"],
location: exampleResourceGroup.location,
resourceGroupName: exampleResourceGroup.name,
});
const exampleSubnet = new azure.network.Subnet("exampleSubnet", {
resourceGroupName: exampleResourceGroup.name,
virtualNetworkName: exampleVirtualNetwork.name,
addressPrefix: "10.0.1.0/24",
});
const exampleCache = new azure.hpc.Cache("exampleCache", {
resourceGroupName: exampleResourceGroup.name,
location: exampleResourceGroup.location,
cacheSizeInGb: 3072,
subnetId: exampleSubnet.id,
skuName: "Standard_2G",
});Create a Cache Resource
new Cache(name: string, args: CacheArgs, opts?: CustomResourceOptions);def Cache(resource_name, opts=None, cache_size_in_gb=None, location=None, name=None, resource_group_name=None, sku_name=None, subnet_id=None, __props__=None);public Cache(string name, CacheArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args CacheArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args CacheArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args CacheArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
Cache Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The Cache resource accepts the following input properties:
- Cache
Size intIn Gb The size of the HPC Cache, in GB. Possible values are
3072,6144,12288,24576, and49152. Changing this forces a new resource to be created.- Resource
Group stringName The name of the Resource Group in which to create the HPC Cache. Changing this forces a new resource to be created.
- Sku
Name string The SKU of HPC Cache to use. Possible values are
Standard_2G,Standard_4GandStandard_8G. Changing this forces a new resource to be created.- Subnet
Id string The ID of the Subnet for the HPC Cache. Changing this forces a new resource to be created.
- Location string
Specifies the supported Azure Region where the HPC Cache should be created. Changing this forces a new resource to be created.
- Name string
The name of the HPC Cache. Changing this forces a new resource to be created.
- Cache
Size intIn Gb The size of the HPC Cache, in GB. Possible values are
3072,6144,12288,24576, and49152. Changing this forces a new resource to be created.- Resource
Group stringName The name of the Resource Group in which to create the HPC Cache. Changing this forces a new resource to be created.
- Sku
Name string The SKU of HPC Cache to use. Possible values are
Standard_2G,Standard_4GandStandard_8G. Changing this forces a new resource to be created.- Subnet
Id string The ID of the Subnet for the HPC Cache. Changing this forces a new resource to be created.
- Location string
Specifies the supported Azure Region where the HPC Cache should be created. Changing this forces a new resource to be created.
- Name string
The name of the HPC Cache. Changing this forces a new resource to be created.
- cache
Size numberIn Gb The size of the HPC Cache, in GB. Possible values are
3072,6144,12288,24576, and49152. Changing this forces a new resource to be created.- resource
Group stringName The name of the Resource Group in which to create the HPC Cache. Changing this forces a new resource to be created.
- sku
Name string The SKU of HPC Cache to use. Possible values are
Standard_2G,Standard_4GandStandard_8G. Changing this forces a new resource to be created.- subnet
Id string The ID of the Subnet for the HPC Cache. Changing this forces a new resource to be created.
- location string
Specifies the supported Azure Region where the HPC Cache should be created. Changing this forces a new resource to be created.
- name string
The name of the HPC Cache. Changing this forces a new resource to be created.
- cache_
size_ floatin_ gb The size of the HPC Cache, in GB. Possible values are
3072,6144,12288,24576, and49152. Changing this forces a new resource to be created.- resource_
group_ strname The name of the Resource Group in which to create the HPC Cache. Changing this forces a new resource to be created.
- sku_
name str The SKU of HPC Cache to use. Possible values are
Standard_2G,Standard_4GandStandard_8G. Changing this forces a new resource to be created.- subnet_
id str The ID of the Subnet for the HPC Cache. Changing this forces a new resource to be created.
- location str
Specifies the supported Azure Region where the HPC Cache should be created. Changing this forces a new resource to be created.
- name str
The name of the HPC Cache. Changing this forces a new resource to be created.
Outputs
All input properties are implicitly available as output properties. Additionally, the Cache resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Mount
Addresses List<string> A list of IP Addresses where the HPC Cache can be mounted.
- Id string
- The provider-assigned unique ID for this managed resource.
- Mount
Addresses []string A list of IP Addresses where the HPC Cache can be mounted.
- id string
- The provider-assigned unique ID for this managed resource.
- mount
Addresses string[] A list of IP Addresses where the HPC Cache can be mounted.
- id str
- The provider-assigned unique ID for this managed resource.
- mount_
addresses List[str] A list of IP Addresses where the HPC Cache can be mounted.
Look up an Existing Cache Resource
Get an existing Cache 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?: CacheState, opts?: CustomResourceOptions): Cachestatic get(resource_name, id, opts=None, cache_size_in_gb=None, location=None, mount_addresses=None, name=None, resource_group_name=None, sku_name=None, subnet_id=None, __props__=None);func GetCache(ctx *Context, name string, id IDInput, state *CacheState, opts ...ResourceOption) (*Cache, error)public static Cache Get(string name, Input<string> id, CacheState? state, CustomResourceOptions? opts = null)- 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.
The following state arguments are supported:
- Cache
Size intIn Gb The size of the HPC Cache, in GB. Possible values are
3072,6144,12288,24576, and49152. Changing this forces a new resource to be created.- Location string
Specifies the supported Azure Region where the HPC Cache should be created. Changing this forces a new resource to be created.
- Mount
Addresses List<string> A list of IP Addresses where the HPC Cache can be mounted.
- Name string
The name of the HPC Cache. Changing this forces a new resource to be created.
- Resource
Group stringName The name of the Resource Group in which to create the HPC Cache. Changing this forces a new resource to be created.
- Sku
Name string The SKU of HPC Cache to use. Possible values are
Standard_2G,Standard_4GandStandard_8G. Changing this forces a new resource to be created.- Subnet
Id string The ID of the Subnet for the HPC Cache. Changing this forces a new resource to be created.
- Cache
Size intIn Gb The size of the HPC Cache, in GB. Possible values are
3072,6144,12288,24576, and49152. Changing this forces a new resource to be created.- Location string
Specifies the supported Azure Region where the HPC Cache should be created. Changing this forces a new resource to be created.
- Mount
Addresses []string A list of IP Addresses where the HPC Cache can be mounted.
- Name string
The name of the HPC Cache. Changing this forces a new resource to be created.
- Resource
Group stringName The name of the Resource Group in which to create the HPC Cache. Changing this forces a new resource to be created.
- Sku
Name string The SKU of HPC Cache to use. Possible values are
Standard_2G,Standard_4GandStandard_8G. Changing this forces a new resource to be created.- Subnet
Id string The ID of the Subnet for the HPC Cache. Changing this forces a new resource to be created.
- cache
Size numberIn Gb The size of the HPC Cache, in GB. Possible values are
3072,6144,12288,24576, and49152. Changing this forces a new resource to be created.- location string
Specifies the supported Azure Region where the HPC Cache should be created. Changing this forces a new resource to be created.
- mount
Addresses string[] A list of IP Addresses where the HPC Cache can be mounted.
- name string
The name of the HPC Cache. Changing this forces a new resource to be created.
- resource
Group stringName The name of the Resource Group in which to create the HPC Cache. Changing this forces a new resource to be created.
- sku
Name string The SKU of HPC Cache to use. Possible values are
Standard_2G,Standard_4GandStandard_8G. Changing this forces a new resource to be created.- subnet
Id string The ID of the Subnet for the HPC Cache. Changing this forces a new resource to be created.
- cache_
size_ floatin_ gb The size of the HPC Cache, in GB. Possible values are
3072,6144,12288,24576, and49152. Changing this forces a new resource to be created.- location str
Specifies the supported Azure Region where the HPC Cache should be created. Changing this forces a new resource to be created.
- mount_
addresses List[str] A list of IP Addresses where the HPC Cache can be mounted.
- name str
The name of the HPC Cache. Changing this forces a new resource to be created.
- resource_
group_ strname The name of the Resource Group in which to create the HPC Cache. Changing this forces a new resource to be created.
- sku_
name str The SKU of HPC Cache to use. Possible values are
Standard_2G,Standard_4GandStandard_8G. Changing this forces a new resource to be created.- subnet_
id str The ID of the Subnet for the HPC Cache. Changing this forces a new resource to be created.
Package Details
- Repository
- https://github.com/pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurermTerraform Provider.