azure-native.hybridcloud.CloudConnection
Explore with Pulumi AI
Resource which represents the managed network connection between Azure Gateways and remote cloud gateways. Azure REST API version: 2023-01-01-preview. Prior API version in Azure Native 1.x: 2023-01-01-preview.
Example Usage
Create a Cloud Connection
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() => 
{
    var cloudConnection = new AzureNative.HybridCloud.CloudConnection("cloudConnection", new()
    {
        CloudConnectionName = "cloudconnection1",
        CloudConnector = new AzureNative.HybridCloud.Inputs.ResourceReferenceArgs
        {
            Id = "/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.HybridCloud/cloudConnectors/123456789012",
        },
        Location = "West US",
        RemoteResourceId = "arn:aws:ec2:us-east-1:123456789012:VPNGateway/vgw-043da592550819c8a",
        ResourceGroupName = "demo-rg",
        SharedKey = "password123",
        VirtualHub = new AzureNative.HybridCloud.Inputs.ResourceReferenceArgs
        {
            Id = "/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.Network/VirtualHubs/testHub",
        },
    });
});
package main
import (
	hybridcloud "github.com/pulumi/pulumi-azure-native-sdk/hybridcloud/v2"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := hybridcloud.NewCloudConnection(ctx, "cloudConnection", &hybridcloud.CloudConnectionArgs{
			CloudConnectionName: pulumi.String("cloudconnection1"),
			CloudConnector: &hybridcloud.ResourceReferenceArgs{
				Id: pulumi.String("/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.HybridCloud/cloudConnectors/123456789012"),
			},
			Location:          pulumi.String("West US"),
			RemoteResourceId:  pulumi.String("arn:aws:ec2:us-east-1:123456789012:VPNGateway/vgw-043da592550819c8a"),
			ResourceGroupName: pulumi.String("demo-rg"),
			SharedKey:         pulumi.String("password123"),
			VirtualHub: &hybridcloud.ResourceReferenceArgs{
				Id: pulumi.String("/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.Network/VirtualHubs/testHub"),
			},
		})
		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.azurenative.hybridcloud.CloudConnection;
import com.pulumi.azurenative.hybridcloud.CloudConnectionArgs;
import com.pulumi.azurenative.hybridcloud.inputs.ResourceReferenceArgs;
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 cloudConnection = new CloudConnection("cloudConnection", CloudConnectionArgs.builder()
            .cloudConnectionName("cloudconnection1")
            .cloudConnector(ResourceReferenceArgs.builder()
                .id("/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.HybridCloud/cloudConnectors/123456789012")
                .build())
            .location("West US")
            .remoteResourceId("arn:aws:ec2:us-east-1:123456789012:VPNGateway/vgw-043da592550819c8a")
            .resourceGroupName("demo-rg")
            .sharedKey("password123")
            .virtualHub(ResourceReferenceArgs.builder()
                .id("/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.Network/VirtualHubs/testHub")
                .build())
            .build());
    }
}
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const cloudConnection = new azure_native.hybridcloud.CloudConnection("cloudConnection", {
    cloudConnectionName: "cloudconnection1",
    cloudConnector: {
        id: "/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.HybridCloud/cloudConnectors/123456789012",
    },
    location: "West US",
    remoteResourceId: "arn:aws:ec2:us-east-1:123456789012:VPNGateway/vgw-043da592550819c8a",
    resourceGroupName: "demo-rg",
    sharedKey: "password123",
    virtualHub: {
        id: "/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.Network/VirtualHubs/testHub",
    },
});
import pulumi
import pulumi_azure_native as azure_native
cloud_connection = azure_native.hybridcloud.CloudConnection("cloudConnection",
    cloud_connection_name="cloudconnection1",
    cloud_connector={
        "id": "/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.HybridCloud/cloudConnectors/123456789012",
    },
    location="West US",
    remote_resource_id="arn:aws:ec2:us-east-1:123456789012:VPNGateway/vgw-043da592550819c8a",
    resource_group_name="demo-rg",
    shared_key="password123",
    virtual_hub={
        "id": "/subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.Network/VirtualHubs/testHub",
    })
resources:
  cloudConnection:
    type: azure-native:hybridcloud:CloudConnection
    properties:
      cloudConnectionName: cloudconnection1
      cloudConnector:
        id: /subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.HybridCloud/cloudConnectors/123456789012
      location: West US
      remoteResourceId: arn:aws:ec2:us-east-1:123456789012:VPNGateway/vgw-043da592550819c8a
      resourceGroupName: demo-rg
      sharedKey: password123
      virtualHub:
        id: /subscriptions/subid/resourceGroups/demo-rg/providers/Microsoft.Network/VirtualHubs/testHub
Create CloudConnection Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new CloudConnection(name: string, args: CloudConnectionArgs, opts?: CustomResourceOptions);@overload
def CloudConnection(resource_name: str,
                    args: CloudConnectionArgs,
                    opts: Optional[ResourceOptions] = None)
@overload
def CloudConnection(resource_name: str,
                    opts: Optional[ResourceOptions] = None,
                    resource_group_name: Optional[str] = None,
                    cloud_connection_name: Optional[str] = None,
                    cloud_connector: Optional[ResourceReferenceArgs] = None,
                    location: Optional[str] = None,
                    remote_resource_id: Optional[str] = None,
                    shared_key: Optional[str] = None,
                    tags: Optional[Mapping[str, str]] = None,
                    virtual_hub: Optional[ResourceReferenceArgs] = None)func NewCloudConnection(ctx *Context, name string, args CloudConnectionArgs, opts ...ResourceOption) (*CloudConnection, error)public CloudConnection(string name, CloudConnectionArgs args, CustomResourceOptions? opts = null)
public CloudConnection(String name, CloudConnectionArgs args)
public CloudConnection(String name, CloudConnectionArgs args, CustomResourceOptions options)
type: azure-native:hybridcloud:CloudConnection
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 CloudConnectionArgs
- 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 CloudConnectionArgs
- 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 CloudConnectionArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args CloudConnectionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args CloudConnectionArgs
- 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 cloudConnectionResource = new AzureNative.HybridCloud.CloudConnection("cloudConnectionResource", new()
{
    ResourceGroupName = "string",
    CloudConnectionName = "string",
    CloudConnector = new AzureNative.HybridCloud.Inputs.ResourceReferenceArgs
    {
        Id = "string",
    },
    Location = "string",
    RemoteResourceId = "string",
    SharedKey = "string",
    Tags = 
    {
        { "string", "string" },
    },
    VirtualHub = new AzureNative.HybridCloud.Inputs.ResourceReferenceArgs
    {
        Id = "string",
    },
});
example, err := hybridcloud.NewCloudConnection(ctx, "cloudConnectionResource", &hybridcloud.CloudConnectionArgs{
	ResourceGroupName:   pulumi.String("string"),
	CloudConnectionName: pulumi.String("string"),
	CloudConnector: &hybridcloud.ResourceReferenceArgs{
		Id: pulumi.String("string"),
	},
	Location:         pulumi.String("string"),
	RemoteResourceId: pulumi.String("string"),
	SharedKey:        pulumi.String("string"),
	Tags: pulumi.StringMap{
		"string": pulumi.String("string"),
	},
	VirtualHub: &hybridcloud.ResourceReferenceArgs{
		Id: pulumi.String("string"),
	},
})
var cloudConnectionResource = new CloudConnection("cloudConnectionResource", CloudConnectionArgs.builder()
    .resourceGroupName("string")
    .cloudConnectionName("string")
    .cloudConnector(ResourceReferenceArgs.builder()
        .id("string")
        .build())
    .location("string")
    .remoteResourceId("string")
    .sharedKey("string")
    .tags(Map.of("string", "string"))
    .virtualHub(ResourceReferenceArgs.builder()
        .id("string")
        .build())
    .build());
cloud_connection_resource = azure_native.hybridcloud.CloudConnection("cloudConnectionResource",
    resource_group_name="string",
    cloud_connection_name="string",
    cloud_connector={
        "id": "string",
    },
    location="string",
    remote_resource_id="string",
    shared_key="string",
    tags={
        "string": "string",
    },
    virtual_hub={
        "id": "string",
    })
const cloudConnectionResource = new azure_native.hybridcloud.CloudConnection("cloudConnectionResource", {
    resourceGroupName: "string",
    cloudConnectionName: "string",
    cloudConnector: {
        id: "string",
    },
    location: "string",
    remoteResourceId: "string",
    sharedKey: "string",
    tags: {
        string: "string",
    },
    virtualHub: {
        id: "string",
    },
});
type: azure-native:hybridcloud:CloudConnection
properties:
    cloudConnectionName: string
    cloudConnector:
        id: string
    location: string
    remoteResourceId: string
    resourceGroupName: string
    sharedKey: string
    tags:
        string: string
    virtualHub:
        id: string
CloudConnection 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 CloudConnection resource accepts the following input properties:
- ResourceGroup stringName 
- The name of the resource group. The name is case insensitive.
- CloudConnection stringName 
- The name of the cloud connection resource
- CloudConnector Pulumi.Azure Native. Hybrid Cloud. Inputs. Resource Reference 
- The cloud connector which discovered the remote resource.
- Location string
- The geo-location where the resource lives
- RemoteResource stringId 
- Identifier for the remote cloud resource
- string
- Shared key of the cloud connection.
- Dictionary<string, string>
- Resource tags.
- VirtualHub Pulumi.Azure Native. Hybrid Cloud. Inputs. Resource Reference 
- The virtualHub to which the cloud connection belongs.
- ResourceGroup stringName 
- The name of the resource group. The name is case insensitive.
- CloudConnection stringName 
- The name of the cloud connection resource
- CloudConnector ResourceReference Args 
- The cloud connector which discovered the remote resource.
- Location string
- The geo-location where the resource lives
- RemoteResource stringId 
- Identifier for the remote cloud resource
- string
- Shared key of the cloud connection.
- map[string]string
- Resource tags.
- VirtualHub ResourceReference Args 
- The virtualHub to which the cloud connection belongs.
- resourceGroup StringName 
- The name of the resource group. The name is case insensitive.
- cloudConnection StringName 
- The name of the cloud connection resource
- cloudConnector ResourceReference 
- The cloud connector which discovered the remote resource.
- location String
- The geo-location where the resource lives
- remoteResource StringId 
- Identifier for the remote cloud resource
- String
- Shared key of the cloud connection.
- Map<String,String>
- Resource tags.
- virtualHub ResourceReference 
- The virtualHub to which the cloud connection belongs.
- resourceGroup stringName 
- The name of the resource group. The name is case insensitive.
- cloudConnection stringName 
- The name of the cloud connection resource
- cloudConnector ResourceReference 
- The cloud connector which discovered the remote resource.
- location string
- The geo-location where the resource lives
- remoteResource stringId 
- Identifier for the remote cloud resource
- string
- Shared key of the cloud connection.
- {[key: string]: string}
- Resource tags.
- virtualHub ResourceReference 
- The virtualHub to which the cloud connection belongs.
- resource_group_ strname 
- The name of the resource group. The name is case insensitive.
- cloud_connection_ strname 
- The name of the cloud connection resource
- cloud_connector ResourceReference Args 
- The cloud connector which discovered the remote resource.
- location str
- The geo-location where the resource lives
- remote_resource_ strid 
- Identifier for the remote cloud resource
- str
- Shared key of the cloud connection.
- Mapping[str, str]
- Resource tags.
- virtual_hub ResourceReference Args 
- The virtualHub to which the cloud connection belongs.
- resourceGroup StringName 
- The name of the resource group. The name is case insensitive.
- cloudConnection StringName 
- The name of the cloud connection resource
- cloudConnector Property Map
- The cloud connector which discovered the remote resource.
- location String
- The geo-location where the resource lives
- remoteResource StringId 
- Identifier for the remote cloud resource
- String
- Shared key of the cloud connection.
- Map<String>
- Resource tags.
- virtualHub Property Map
- The virtualHub to which the cloud connection belongs.
Outputs
All input properties are implicitly available as output properties. Additionally, the CloudConnection resource produces the following output properties:
- Etag string
- A unique read-only string that changes whenever the resource is updated.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The name of the resource
- ProvisioningState string
- The provisioning state of the cloud collection resource.
- SystemData Pulumi.Azure Native. Hybrid Cloud. Outputs. System Data Response 
- Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- Etag string
- A unique read-only string that changes whenever the resource is updated.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The name of the resource
- ProvisioningState string
- The provisioning state of the cloud collection resource.
- SystemData SystemData Response 
- Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- etag String
- A unique read-only string that changes whenever the resource is updated.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The name of the resource
- provisioningState String
- The provisioning state of the cloud collection resource.
- systemData SystemData Response 
- Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- etag string
- A unique read-only string that changes whenever the resource is updated.
- id string
- The provider-assigned unique ID for this managed resource.
- name string
- The name of the resource
- provisioningState string
- The provisioning state of the cloud collection resource.
- systemData SystemData Response 
- Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- etag str
- A unique read-only string that changes whenever the resource is updated.
- id str
- The provider-assigned unique ID for this managed resource.
- name str
- The name of the resource
- provisioning_state str
- The provisioning state of the cloud collection resource.
- system_data SystemData Response 
- Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type str
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- etag String
- A unique read-only string that changes whenever the resource is updated.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The name of the resource
- provisioningState String
- The provisioning state of the cloud collection resource.
- systemData Property Map
- Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
Supporting Types
ResourceReference, ResourceReferenceArgs    
- Id string
- Resource ID.
- Id string
- Resource ID.
- id String
- Resource ID.
- id string
- Resource ID.
- id str
- Resource ID.
- id String
- Resource ID.
ResourceReferenceResponse, ResourceReferenceResponseArgs      
- Id string
- Resource ID.
- Id string
- Resource ID.
- id String
- Resource ID.
- id string
- Resource ID.
- id str
- Resource ID.
- id String
- Resource ID.
SystemDataResponse, SystemDataResponseArgs      
- CreatedAt string
- The timestamp of resource creation (UTC).
- CreatedBy string
- The identity that created the resource.
- CreatedBy stringType 
- The type of identity that created the resource.
- LastModified stringAt 
- The timestamp of resource last modification (UTC)
- LastModified stringBy 
- The identity that last modified the resource.
- LastModified stringBy Type 
- The type of identity that last modified the resource.
- CreatedAt string
- The timestamp of resource creation (UTC).
- CreatedBy string
- The identity that created the resource.
- CreatedBy stringType 
- The type of identity that created the resource.
- LastModified stringAt 
- The timestamp of resource last modification (UTC)
- LastModified stringBy 
- The identity that last modified the resource.
- LastModified stringBy Type 
- The type of identity that last modified the resource.
- createdAt String
- The timestamp of resource creation (UTC).
- createdBy String
- The identity that created the resource.
- createdBy StringType 
- The type of identity that created the resource.
- lastModified StringAt 
- The timestamp of resource last modification (UTC)
- lastModified StringBy 
- The identity that last modified the resource.
- lastModified StringBy Type 
- The type of identity that last modified the resource.
- createdAt string
- The timestamp of resource creation (UTC).
- createdBy string
- The identity that created the resource.
- createdBy stringType 
- The type of identity that created the resource.
- lastModified stringAt 
- The timestamp of resource last modification (UTC)
- lastModified stringBy 
- The identity that last modified the resource.
- lastModified stringBy Type 
- The type of identity that last modified the resource.
- created_at str
- The timestamp of resource creation (UTC).
- created_by str
- The identity that created the resource.
- created_by_ strtype 
- The type of identity that created the resource.
- last_modified_ strat 
- The timestamp of resource last modification (UTC)
- last_modified_ strby 
- The identity that last modified the resource.
- last_modified_ strby_ type 
- The type of identity that last modified the resource.
- createdAt String
- The timestamp of resource creation (UTC).
- createdBy String
- The identity that created the resource.
- createdBy StringType 
- The type of identity that created the resource.
- lastModified StringAt 
- The timestamp of resource last modification (UTC)
- lastModified StringBy 
- The identity that last modified the resource.
- lastModified StringBy Type 
- The type of identity that last modified the resource.
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:hybridcloud:CloudConnection cloudconnection1 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridCloud/cloudConnections/{cloudConnectionName} 
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0