github.com/opentelekomcloud/gophertelekomcloud@v0.9.3/openstack/css/v1/snapshots/Enable.go (about)

     1  package snapshots
     2  
     3  import "github.com/opentelekomcloud/gophertelekomcloud"
     4  
     5  // Enable will enable the Snapshot function with the provided ID.
     6  func Enable(client *golangsdk.ServiceClient, clusterId string) (err error) {
     7  	_, err = client.Post(client.ServiceURL("clusters", clusterId, "index_snapshot/auto_setting"), nil, nil, &golangsdk.RequestOpts{
     8  		OkCodes:     []int{200},
     9  		MoreHeaders: map[string]string{"Content-Type": "application/json", "X-Language": "en-us"},
    10  	})
    11  	return
    12  }