github.com/opentelekomcloud/gophertelekomcloud@v0.9.3/openstack/rds/v3/instances/EnlargeVolume.go (about) 1 package instances 2 3 import ( 4 "github.com/opentelekomcloud/gophertelekomcloud" 5 "github.com/opentelekomcloud/gophertelekomcloud/internal/build" 6 ) 7 8 type EnlargeVolumeRdsOpts struct { 9 InstanceId string `json:"-"` 10 // The minimum start value of each scaling is 10 GB. A DB instance can be scaled up only by a multiple of 10 GB. Value range: 10 GB to 4000 GB 11 Size int `json:"size" required:"true"` 12 } 13 14 func EnlargeVolume(client *golangsdk.ServiceClient, opts EnlargeVolumeRdsOpts) (*string, error) { 15 b, err := build.RequestBody(&opts, "enlarge_volume") 16 if err != nil { 17 return nil, err 18 } 19 20 // POST https://{Endpoint}/v3/{project_id}/instances/{instance_id}/action 21 raw, err := client.Post(client.ServiceURL("instances", opts.InstanceId, "action"), b, nil, nil) 22 return extraJob(err, raw) 23 }