mirror of
https://github.com/kubernetes/kubernetes.git
synced 2026-02-19 02:38:07 -05:00
| .. | ||
| BUILD | ||
| LICENSE | ||
| quobyte.go | ||
| README.md | ||
| rpc_client.go | ||
| types.go | ||
Quobyte API Clients
Get the quoybte api client
go get github.com/quobyte/api
Usage
package main
import (
"log"
quobyte_api "github.com/quobyte/api"
)
func main() {
client := quobyte_api.NewQuobyteClient("http://apiserver:7860", "user", "password")
req := &quobyte_api.CreateVolumeRequest{
Name: "MyVolume",
RootUserID: "root",
RootGroupID: "root",
ConfigurationName: "BASE",
}
volumeUUID, err := client.CreateVolume(req)
if err != nil {
log.Fatalf("Error:", err)
}
log.Printf("%s", volumeUUID)
}