Skip to content

Commit

Permalink
Merge branch 'DOC-4215' into 'master'
Browse files Browse the repository at this point in the history
DOC-4215: Added and removed parameters + added example

See merge request documentation/doc-terraform-template!78
  • Loading branch information
aurelienmoreira committed Feb 7, 2024
2 parents d9914cb + ab5df32 commit 8fcab83
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 3 deletions.
4 changes: 3 additions & 1 deletion Content/data-sources/security_group-addprop.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@ argument:
name: filter
description: "(Optional) A combination of a filter name and one or more filter values. You can specify this argument for as many filter names as you need. The filter name can be any of the following:"
filter.tags:
description: "The key/value combinations of the tags associated with the security groups, in the following format: `TAGKEY=TAGVALUE`."
description: "The key/value combinations of the tags associated with the security groups, in the following format: `TAGKEY=TAGVALUE`."
remove:
- account_ids
24 changes: 24 additions & 0 deletions Content/resources/vm-addprop.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,32 @@ argument:
- bsu_optimized
add:
get_admin_password: "(Optional) (Windows VM only) If true, waits for the administrator password of the VM to become available in order to retrieve the VM. The password is exported to the `admin_password` attribute."
nics: |
(Optional) One or more NICs. If you specify this parameter, you must not specify the `subnet_id` and `subregion_name` parameters. To define a NIC as the primary network interface of the VM, use the `primary_nic` argument.
* `delete_on_vm_deletion` - (Optional) If true, the NIC is deleted when the VM is terminated. You can specify this parameter only for a new NIC. To modify this value for an existing NIC, see [UpdateNic](https://docs.outscale.com/api#updatenic).
* `description` - (Optional) The description of the NIC, if you are creating a NIC when creating the VM.
* `device_number` - (Optional) The index of the VM device for the NIC attachment (between `1` and `7`, both included). This parameter is required if you create a NIC when creating the VM.
* `nic_id` - (Optional) The ID of the NIC, if you are attaching an existing NIC when creating a VM.
* `private_ips` - (Optional) One or more private IPs to assign to the NIC, if you create a NIC when creating a VM. Only one private IP can be the primary private IP.
* `is_primary` - (Optional) If true, the IP is the primary private IP of the NIC.
* `private_ip` - (Optional) The private IP of the NIC.
* `secondary_private_ip_count` - (Optional) The number of secondary private IPs, if you create a NIC when creating a VM. This parameter cannot be specified if you specified more than one private IP in the `private_ips` parameter.
* `security_group_ids` - (Optional) One or more IDs of security groups for the NIC, if you create a NIC when creating a VM.
* `subnet_id` - (Optional) The ID of the Subnet for the NIC, if you create a NIC when creating a VM. This parameter is required if you create a NIC when creating the VM.
placement_subregion_name: (Optional) The name of the Subregion where the VM is placed.
placement_tenancy: (Optional) The tenancy of the VM (`default` | `dedicated`).
primary_nic: |
(Optional) The primary network interface of the VM.
* `delete_on_vm_deletion` - (Optional) If true, the NIC is deleted when the VM is terminated. You can specify this parameter only for a new NIC. To modify this value for an existing NIC, see [UpdateNic](https://docs.outscale.com/api#updatenic).
* `description` - (Optional) The description of the NIC, if you are creating a NIC when creating the VM.
* `device_number` - (Optional) The index of the VM device for the NIC attachment (must be `0`). This parameter is required if you create a NIC when creating the VM.
* `nic_id` - (Optional) The ID of the NIC, if you are attaching an existing NIC when creating a VM.
* `private_ips` - (Optional) One or more private IPs to assign to the NIC, if you create a NIC when creating a VM. Only one private IP can be the primary private IP.
* `is_primary` - (Optional) If true, the IP is the primary private IP of the NIC.
* `private_ip` - (Optional) The private IP of the NIC.
* `secondary_private_ip_count` - (Optional) The number of secondary private IPs, if you create a NIC when creating a VM. This parameter cannot be specified if you specified more than one private IP in the `private_ips` parameter.
* `security_group_ids` - (Optional) One or more IDs of security groups for the NIC, if you create a NIC when creating a VM.
* `subnet_id` - (Optional) The ID of the Subnet for the NIC, if you create a NIC when creating a VM. This parameter is required if you create a NIC when creating the VM.
state: The state of the VM (`running` | `stopped`). If set to `stopped`, the VM is stopped regardless of the value of the `vm_initiated_shutdown_behavior` argument.
tags: (Optional) A tag to add to this resource. You can specify this argument several times.
tags.key: (Required) The key of the tag, with a minimum of 1 character.
Expand Down
2 changes: 1 addition & 1 deletion Content/resources/vm-example.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ resource "outscale_vm" "vm04" {
image_id = var.image_id
vm_type = "c4.large"
keypair_name = var.keypair_name
nics {
primary_nic {
nic_id = outscale_nic.nic01.nic_id
device_number = "0"
}
Expand Down
1 change: 1 addition & 0 deletions Content/resources/volume-addprop.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ argument:
tags: (Optional) A tag to add to this resource. You can specify this argument several times.
tags.key: (Required) The key of the tag, with a minimum of 1 character.
tags.value: (Required) The value of the tag, between 0 and 255 characters.
termination_snapshot_name: (Optional) Whether you want to create a snapshot before the volume deletion.
attribute:
rename:
iops:
Expand Down
14 changes: 13 additions & 1 deletion Content/resources/volume-example.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
### Creating an io1 volume

```hcl
resource "outscale_volume" "volume01" {
subregion_name = "${var.region}a"
size = 10
iops = 100
volume_type = "io1"
}
```
```

### Creating a snapshot before volume deletion

```hcl
resource "outscale_volume" "volume01" {
termination_snapshot_name = "deleting_volume_snap"
subregion_name = "${var.region}a"
size = 40
}
``````

0 comments on commit 8fcab83

Please sign in to comment.