provider/openstack: blockstorage volume attach code review updates

This commit is contained in:
Joe Topjian 2016-11-22 15:27:23 +00:00
parent 22dd265132
commit 4cc46937e8
2 changed files with 2 additions and 1 deletions

View File

@ -16,7 +16,6 @@ func resourceBlockStorageVolumeAttachV2() *schema.Resource {
return &schema.Resource{
Create: resourceBlockStorageVolumeAttachV2Create,
Read: resourceBlockStorageVolumeAttachV2Read,
Update: nil,
Delete: resourceBlockStorageVolumeAttachV2Delete,
Importer: &schema.ResourceImporter{
State: schema.ImportStatePassthrough,
@ -233,6 +232,7 @@ func blockStorageVolumeAttachV2AttachMode(v string) (volumeactions.AttachMode, e
var attachError error
switch v {
case "":
attachMode = ""
case "ro":
attachMode = volumeactions.ReadOnly
case "rw":

View File

@ -53,6 +53,7 @@ The following arguments are supported:
* `attach_mode` - (Optional) Specify whether to attach the volume as Read-Only
(`ro`) or Read-Write (`rw`). Only values of `ro` and `rw` are accepted.
If left unspecified, the Block Storage API will apply a default of `rw`.
## Attributes Reference