From 2559c19c8d522fdf77b99f8c6b18a892a1a32ce4 Mon Sep 17 00:00:00 2001 From: Paul Stack Date: Tue, 19 Jul 2016 17:22:30 +0100 Subject: [PATCH] Website: Adding an import section to the bottom of the page of importable resources (#7703) * docs/digitalocean: Adding an import section to the bottom of the DO importable resources * docs/azurerm: Adding the Import sections for the AzureRM Importable resources * docs/aws: Adding the import sections to the AWS provider pages --- .../providers/aws/r/simpledb_domain.html.markdown | 8 ++++++++ .../docs/providers/aws/r/sns_topic.html.markdown | 7 +++++++ .../aws/r/sns_topic_subscription.html.markdown | 8 ++++++++ .../docs/providers/aws/r/sqs_queue.html.markdown | 8 ++++++++ .../source/docs/providers/aws/r/subnet.html.markdown | 9 +++++++++ website/source/docs/providers/aws/r/vpc.html.markdown | 8 ++++++++ .../providers/aws/r/vpc_dhcp_options.html.markdown | 9 +++++++++ .../docs/providers/aws/r/vpc_endpoint.html.markdown | 9 +++++++++ .../docs/providers/aws/r/vpc_peering.html.markdown | 8 ++++++++ .../docs/providers/aws/r/vpn_connection.html.markdown | 9 +++++++++ .../docs/providers/aws/r/vpn_gateway.html.markdown | 8 ++++++++ .../azurerm/r/availability_set.html.markdown | 11 ++++++++++- .../docs/providers/azurerm/r/dns_zone.html.markdown | 9 +++++++++ .../azurerm/r/local_network_gateway.html.markdown | 8 ++++++++ .../azurerm/r/network_security_group.html.markdown | 9 +++++++++ .../azurerm/r/network_security_rule.html.markdown | 11 ++++++++++- .../docs/providers/azurerm/r/public_ip.html.markdown | 11 ++++++++++- .../providers/azurerm/r/resource_group.html.markdown | 9 +++++++++ .../azurerm/r/sql_firewall_rule.html.markdown | 11 ++++++++++- .../providers/azurerm/r/storage_account.html.markdown | 9 +++++++++ .../providers/azurerm/r/virtual_network.html.markdown | 9 +++++++++ .../source/docs/providers/do/r/domain.html.markdown | 9 +++++++++ .../source/docs/providers/do/r/droplet.html.markdown | 8 ++++++++ .../docs/providers/do/r/floating_ip.html.markdown | 8 ++++++++ .../source/docs/providers/do/r/ssh_key.html.markdown | 8 ++++++++ website/source/docs/providers/do/r/tag.html.markdown | 9 +++++++++ website/source/docs/providers/do/r/volume.markdown | 11 ++++++++++- 27 files changed, 236 insertions(+), 5 deletions(-) diff --git a/website/source/docs/providers/aws/r/simpledb_domain.html.markdown b/website/source/docs/providers/aws/r/simpledb_domain.html.markdown index 52c324652..e63bae36d 100644 --- a/website/source/docs/providers/aws/r/simpledb_domain.html.markdown +++ b/website/source/docs/providers/aws/r/simpledb_domain.html.markdown @@ -29,3 +29,11 @@ The following arguments are supported: The following attributes are exported: * `id` - The name of the SimpleDB domain + +## Import + +SimpleDB Domains can be imported using the `name`, e.g. + +``` +terraform import aws_simpledb_domain.users users +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/sns_topic.html.markdown b/website/source/docs/providers/aws/r/sns_topic.html.markdown index b17d5536f..c0094f2bf 100644 --- a/website/source/docs/providers/aws/r/sns_topic.html.markdown +++ b/website/source/docs/providers/aws/r/sns_topic.html.markdown @@ -34,3 +34,10 @@ The following attributes are exported: * `id` - The ARN of the SNS topic * `arn` - The ARN of the SNS topic, as a more obvious property (clone of id) +## Import + +SNS Topics can be imported using the `topic arn`, e.g. + +``` +terraform import aws_sns_topic.user_updates arn:aws:sns:us-west-2:0123456789012:my-topic +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/sns_topic_subscription.html.markdown b/website/source/docs/providers/aws/r/sns_topic_subscription.html.markdown index ab4ffd594..0bc6e5b89 100644 --- a/website/source/docs/providers/aws/r/sns_topic_subscription.html.markdown +++ b/website/source/docs/providers/aws/r/sns_topic_subscription.html.markdown @@ -96,3 +96,11 @@ The following attributes are exported: * `endpoint` - The full endpoint to send data to (SQS ARN, HTTP(S) URL, Application ARN, SMS number, etc.) * `arn` - The ARN of the subscription stored as a more user-friendly property + +## Import + +SNS Topic Subscriptions can be imported using the `subscription arn`, e.g. + +``` +terraform import aws_sns_topic_subscription.user_updates_sqs_target arn:aws:sns:us-west-2:0123456789012:my-topic:8a21d249-4329-4871-acc6-7be709c6ea7f +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/sqs_queue.html.markdown b/website/source/docs/providers/aws/r/sqs_queue.html.markdown index 8fab2aa2f..1140c07e1 100644 --- a/website/source/docs/providers/aws/r/sqs_queue.html.markdown +++ b/website/source/docs/providers/aws/r/sqs_queue.html.markdown @@ -40,3 +40,11 @@ The following attributes are exported: * `id` - The URL for the created Amazon SQS queue. * `arn` - The ARN of the SQS queue + +## Import + +SQS Queues can be imported using the `queue url`, e.g. + +``` +terraform import aws_sqs_queue.public_queue https://queue.amazonaws.com/80398EXAMPLE/MyQueue +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/subnet.html.markdown b/website/source/docs/providers/aws/r/subnet.html.markdown index 3737ed380..ba96ba77f 100644 --- a/website/source/docs/providers/aws/r/subnet.html.markdown +++ b/website/source/docs/providers/aws/r/subnet.html.markdown @@ -44,3 +44,12 @@ The following attributes are exported: * `cidr_block` - The CIDR block for the subnet. * `vpc_id` - The VPC ID. + + +## Import + +Subnets can be imported using the `subnet id`, e.g. + +``` +terraform import aws_subnet.public_subnet subnet-9d4a7b6c +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/vpc.html.markdown b/website/source/docs/providers/aws/r/vpc.html.markdown index 8cf089b5c..fafcc0097 100644 --- a/website/source/docs/providers/aws/r/vpc.html.markdown +++ b/website/source/docs/providers/aws/r/vpc.html.markdown @@ -64,3 +64,11 @@ The following attributes are exported: [1]: http://docs.aws.amazon.com/fr_fr/AWSEC2/latest/UserGuide/vpc-classiclink.html + +## Import + +VPNs can be imported using the `vpn id`, e.g. + +``` +terraform import aws_vpn.test_vpn vpc-a01106c2 +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/vpc_dhcp_options.html.markdown b/website/source/docs/providers/aws/r/vpc_dhcp_options.html.markdown index a890ebdc7..5e030c509 100644 --- a/website/source/docs/providers/aws/r/vpc_dhcp_options.html.markdown +++ b/website/source/docs/providers/aws/r/vpc_dhcp_options.html.markdown @@ -61,3 +61,12 @@ The following attributes are exported: You can find more technical documentation about DHCP Options Set in the official [AWS User Guide](https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_DHCP_Options.html). + + +## Import + +VPC DHCP Options can be imported using the `dhcp options id`, e.g. + +``` +terraform import aws_vpc_dhcp_options.my_options dopt-d9070ebb +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/vpc_endpoint.html.markdown b/website/source/docs/providers/aws/r/vpc_endpoint.html.markdown index c67c757a5..6bdf31ad8 100644 --- a/website/source/docs/providers/aws/r/vpc_endpoint.html.markdown +++ b/website/source/docs/providers/aws/r/vpc_endpoint.html.markdown @@ -36,3 +36,12 @@ The following attributes are exported: * `id` - The ID of the VPC endpoint. * `prefix_list_id` - The prefix list ID of the exposed service. + + +## Import + +VPN Endpoints can be imported using the `vpc endpoint id`, e.g. + +``` +terraform import aws_vpc_endpoint.endpoint1 vpce-3ecf2a57 +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/vpc_peering.html.markdown b/website/source/docs/providers/aws/r/vpc_peering.html.markdown index e8073f3bb..c20b75bcb 100644 --- a/website/source/docs/providers/aws/r/vpc_peering.html.markdown +++ b/website/source/docs/providers/aws/r/vpc_peering.html.markdown @@ -66,3 +66,11 @@ The following attributes are exported: ## Notes If you are not the owner of both VPCs, or do not enable auto_accept you will still have to accept the peering with the AWS Console, aws-cli or aws-sdk-go. + +## Import + +VPC Peering resources can be imported using the `vpc peering id`, e.g. + +``` +terraform import aws_vpc_peering_connection.test_connection pcx-111aaa111 +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/vpn_connection.html.markdown b/website/source/docs/providers/aws/r/vpn_connection.html.markdown index c1f835ab2..4d1dbdf21 100644 --- a/website/source/docs/providers/aws/r/vpn_connection.html.markdown +++ b/website/source/docs/providers/aws/r/vpn_connection.html.markdown @@ -61,3 +61,12 @@ The following attributes are exported: * `tunnel2_preshared_key` - The preshared key of the second VPN tunnel. * `type` - The type of VPN connection. * `vpn_gateway_id` - The ID of the virtual private gateway to which the connection is attached. + + +## Import + +VPN Connections can be imported using the `vpn connection id`, e.g. + +``` +terraform import aws_vpn_connection.testvpnconnection vpn-40f41529 +``` \ No newline at end of file diff --git a/website/source/docs/providers/aws/r/vpn_gateway.html.markdown b/website/source/docs/providers/aws/r/vpn_gateway.html.markdown index 2dcb2a363..956cfc3c2 100644 --- a/website/source/docs/providers/aws/r/vpn_gateway.html.markdown +++ b/website/source/docs/providers/aws/r/vpn_gateway.html.markdown @@ -36,3 +36,11 @@ The following attributes are exported: * `id` - The ID of the VPN Gateway. + +## Import + +VPN Gateways can be imported using the `vpn gateway id`, e.g. + +``` +terraform import aws_vpn_gateway.testvpngateway vgw-9a4cacf3 +``` \ No newline at end of file diff --git a/website/source/docs/providers/azurerm/r/availability_set.html.markdown b/website/source/docs/providers/azurerm/r/availability_set.html.markdown index cd60368d0..8e9dc1995 100644 --- a/website/source/docs/providers/azurerm/r/availability_set.html.markdown +++ b/website/source/docs/providers/azurerm/r/availability_set.html.markdown @@ -50,4 +50,13 @@ The following arguments are supported: The following attributes are exported: -* `id` - The virtual AvailabilitySet ID. \ No newline at end of file +* `id` - The virtual AvailabilitySet ID. + + +## Import + +Availability Sets can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_availability_set.group1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.Compute/availabilitySets/webAvailSet +``` diff --git a/website/source/docs/providers/azurerm/r/dns_zone.html.markdown b/website/source/docs/providers/azurerm/r/dns_zone.html.markdown index 23aed869c..cc6931f32 100644 --- a/website/source/docs/providers/azurerm/r/dns_zone.html.markdown +++ b/website/source/docs/providers/azurerm/r/dns_zone.html.markdown @@ -39,3 +39,12 @@ The following attributes are exported: * `id` - The DNS Zone ID. * `max_number_of_record_sets` - (Optional) Maximum number of Records in the zone. Defaults to `1000`. * `number_of_record_sets` - (Optional) The number of records already in the zone. + + +## Import + +DNS Zones can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_dns_zone.zone1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.Network/dnsZones/zone1 +``` \ No newline at end of file diff --git a/website/source/docs/providers/azurerm/r/local_network_gateway.html.markdown b/website/source/docs/providers/azurerm/r/local_network_gateway.html.markdown index 1f2bbe0f9..9d9c188b6 100644 --- a/website/source/docs/providers/azurerm/r/local_network_gateway.html.markdown +++ b/website/source/docs/providers/azurerm/r/local_network_gateway.html.markdown @@ -46,3 +46,11 @@ The following arguments are supported: The following attributes are exported: * `id` - The local network gateway unique ID within Azure. + +## Import + +Local Network Gateways can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_local_network_gateway.lng1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/microsoft.network/localnetworkgateways/lng1 +``` diff --git a/website/source/docs/providers/azurerm/r/network_security_group.html.markdown b/website/source/docs/providers/azurerm/r/network_security_group.html.markdown index 019b10e8f..498f90872 100644 --- a/website/source/docs/providers/azurerm/r/network_security_group.html.markdown +++ b/website/source/docs/providers/azurerm/r/network_security_group.html.markdown @@ -88,3 +88,12 @@ The `security_rule` block supports: The following attributes are exported: * `id` - The Network Security Group ID. + + +## Import + +Network Security Groups can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_network_security_group.group1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.Network/networkSecurityGroups/mySecurityGroup +``` diff --git a/website/source/docs/providers/azurerm/r/network_security_rule.html.markdown b/website/source/docs/providers/azurerm/r/network_security_rule.html.markdown index 061175fa4..3b5e58d10 100644 --- a/website/source/docs/providers/azurerm/r/network_security_rule.html.markdown +++ b/website/source/docs/providers/azurerm/r/network_security_rule.html.markdown @@ -72,4 +72,13 @@ The following arguments are supported: The following attributes are exported: -* `id` - The Network Security Rule ID. \ No newline at end of file +* `id` - The Network Security Rule ID. + + +## Import + +Network Security Rules can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_network_security_rule.rule1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.Network/networkSecurityGroups/mySecurityGroup/securityRules/rule1 +``` \ No newline at end of file diff --git a/website/source/docs/providers/azurerm/r/public_ip.html.markdown b/website/source/docs/providers/azurerm/r/public_ip.html.markdown index 5dd1714ab..85f77e3c0 100644 --- a/website/source/docs/providers/azurerm/r/public_ip.html.markdown +++ b/website/source/docs/providers/azurerm/r/public_ip.html.markdown @@ -58,4 +58,13 @@ The following attributes are exported: * `id` - The Public IP ID. * `ip_address` - The IP address value that was allocated. -* `fqdn` - Fully qualified domain name of the A DNS record associated with the public IP. This is the concatenation of the domainNameLabel and the regionalized DNS zone \ No newline at end of file +* `fqdn` - Fully qualified domain name of the A DNS record associated with the public IP. This is the concatenation of the domainNameLabel and the regionalized DNS zone + + +## Import + +Public IPs can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_public_ip.myPublicIp /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.Network/publicIPAddresses/myPublicIpAddress1 +``` \ No newline at end of file diff --git a/website/source/docs/providers/azurerm/r/resource_group.html.markdown b/website/source/docs/providers/azurerm/r/resource_group.html.markdown index 0ba13feed..0c51cba96 100644 --- a/website/source/docs/providers/azurerm/r/resource_group.html.markdown +++ b/website/source/docs/providers/azurerm/r/resource_group.html.markdown @@ -40,3 +40,12 @@ The following arguments are supported: The following attributes are exported: * `id` - The resource group ID. + + +## Import + +Resource Groups can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_resource_group.mygroup /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myresourcegroup +``` diff --git a/website/source/docs/providers/azurerm/r/sql_firewall_rule.html.markdown b/website/source/docs/providers/azurerm/r/sql_firewall_rule.html.markdown index 90a50332b..828e046f1 100644 --- a/website/source/docs/providers/azurerm/r/sql_firewall_rule.html.markdown +++ b/website/source/docs/providers/azurerm/r/sql_firewall_rule.html.markdown @@ -55,4 +55,13 @@ The following arguments are supported: The following attributes are exported: -* `id` - The SQL Firewall Rule ID. \ No newline at end of file +* `id` - The SQL Firewall Rule ID. + +## Import + +SQL Firewall Rules can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_sql_firewall_rule.rule1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myresourcegroup/providers/Microsoft.Sql/servers/myserver/firewallRules/rule1 +``` + diff --git a/website/source/docs/providers/azurerm/r/storage_account.html.markdown b/website/source/docs/providers/azurerm/r/storage_account.html.markdown index 5bc4d0a5d..8e470365a 100644 --- a/website/source/docs/providers/azurerm/r/storage_account.html.markdown +++ b/website/source/docs/providers/azurerm/r/storage_account.html.markdown @@ -72,3 +72,12 @@ The following attributes are exported in addition to the arguments listed above: * `primary_file_endpoint` - The endpoint URL for file storage in the primary location. * `primary_access_key` - The primary access key for the storage account * `secondary_access_key` - The secondary access key for the storage account + +## Import + +Virtual Networks can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_storage_account.storageAcc1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myresourcegroup/providers/Microsoft.Storage/storageAccounts/myaccount +``` + diff --git a/website/source/docs/providers/azurerm/r/virtual_network.html.markdown b/website/source/docs/providers/azurerm/r/virtual_network.html.markdown index 6d75cead6..4e8b87175 100644 --- a/website/source/docs/providers/azurerm/r/virtual_network.html.markdown +++ b/website/source/docs/providers/azurerm/r/virtual_network.html.markdown @@ -80,3 +80,12 @@ The `subnet` block supports: The following attributes are exported: * `id` - The virtual NetworkConfiguration ID. + + +## Import + +Virtual Networks can be imported using the `resource id`, e.g. + +``` +terraform import azurerm_virtual_network.testNetwork /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.Network/virtualNetworks/myvnet1 +``` \ No newline at end of file diff --git a/website/source/docs/providers/do/r/domain.html.markdown b/website/source/docs/providers/do/r/domain.html.markdown index 5580b63d2..1cc3c45bd 100644 --- a/website/source/docs/providers/do/r/domain.html.markdown +++ b/website/source/docs/providers/do/r/domain.html.markdown @@ -35,3 +35,12 @@ The following attributes are exported: * `id` - The name of the domain + + +## Import + +Domains can be imported using the `domain name`, e.g. + +``` +terraform import digitalocean_domain.mydomain mytestdomain.com +``` \ No newline at end of file diff --git a/website/source/docs/providers/do/r/droplet.html.markdown b/website/source/docs/providers/do/r/droplet.html.markdown index 8265e6803..7c98a9731 100644 --- a/website/source/docs/providers/do/r/droplet.html.markdown +++ b/website/source/docs/providers/do/r/droplet.html.markdown @@ -70,3 +70,11 @@ The following attributes are exported: * `status` - The status of the droplet * `tags` - The tags associated with the droplet * `volume_ids` - A list of the attached block storage volumes + +## Import + +Droplets can be imported using the droplet `id`, e.g. + +``` +terraform import digitalocean_droplet.mydroplet 100823 +``` diff --git a/website/source/docs/providers/do/r/floating_ip.html.markdown b/website/source/docs/providers/do/r/floating_ip.html.markdown index a91644369..7f32932b0 100644 --- a/website/source/docs/providers/do/r/floating_ip.html.markdown +++ b/website/source/docs/providers/do/r/floating_ip.html.markdown @@ -42,3 +42,11 @@ The following arguments are supported: The following attributes are exported: * `ip_address` - The IP Address of the resource + +## Import + +Floating IPs can be imported using the `ip`, e.g. + +``` +terraform import digitalocean_floating_ip.myip 192.168.0.1 +``` \ No newline at end of file diff --git a/website/source/docs/providers/do/r/ssh_key.html.markdown b/website/source/docs/providers/do/r/ssh_key.html.markdown index 7a8033519..a97ded95e 100644 --- a/website/source/docs/providers/do/r/ssh_key.html.markdown +++ b/website/source/docs/providers/do/r/ssh_key.html.markdown @@ -39,3 +39,11 @@ The following attributes are exported: * `name` - The name of the SSH key * `public_key` - The text of the public key * `fingerprint` - The fingerprint of the SSH key + +## Import + +SSH Keys can be imported using the `ssh key id`, e.g. + +``` +terraform import digitalocean_ssh_key.mykey 263654 +``` \ No newline at end of file diff --git a/website/source/docs/providers/do/r/tag.html.markdown b/website/source/docs/providers/do/r/tag.html.markdown index 02e0a9694..4e25daa3f 100644 --- a/website/source/docs/providers/do/r/tag.html.markdown +++ b/website/source/docs/providers/do/r/tag.html.markdown @@ -43,3 +43,12 @@ The following attributes are exported: * `id` - The name of the tag * `name` - The name of the tag + + +## Import + +Tags can be imported using the `name`, e.g. + +``` +terraform import digitalocean_tag.mytag tagname +``` \ No newline at end of file diff --git a/website/source/docs/providers/do/r/volume.markdown b/website/source/docs/providers/do/r/volume.markdown index d14416eb6..e8441caa7 100644 --- a/website/source/docs/providers/do/r/volume.markdown +++ b/website/source/docs/providers/do/r/volume.markdown @@ -42,4 +42,13 @@ The following arguments are supported: The following attributes are exported: -* `id` - The unique identifier for the block storage volume. \ No newline at end of file +* `id` - The unique identifier for the block storage volume. + + +## Import + +Volumes can be imported using the `volume id`, e.g. + +``` +terraform import digitalocean_volume.volumea 506f78a4-e098-11e5-ad9f-000f53306ae1 +``` \ No newline at end of file