github.com/zhuohuang-hust/src-cbuild@v0.0.0-20230105071821-c7aab3e7c840/api/types/volume.go (about)

     1  package types
     2  
     3  // This file was generated by the swagger tool.
     4  // Editing this file might prove futile when you re-run the swagger generate command
     5  
     6  // Volume volume
     7  // swagger:model Volume
     8  type Volume struct {
     9  
    10  	// Name of the volume driver used by the volume.
    11  	// Required: true
    12  	Driver string `json:"Driver"`
    13  
    14  	// User-defined key/value metadata.
    15  	// Required: true
    16  	Labels map[string]string `json:"Labels"`
    17  
    18  	// Mount path of the volume on the host.
    19  	// Required: true
    20  	Mountpoint string `json:"Mountpoint"`
    21  
    22  	// Name of the volume.
    23  	// Required: true
    24  	Name string `json:"Name"`
    25  
    26  	// The driver specific options used when creating the volume.
    27  	// Required: true
    28  	Options map[string]string `json:"Options"`
    29  
    30  	// The level at which the volume exists. Either `global` for cluster-wide, or `local` for machine level.
    31  	// Required: true
    32  	Scope string `json:"Scope"`
    33  
    34  	// Low-level details about the volume, provided by the volume driver.
    35  	// Details are returned as a map with key/value pairs:
    36  	// `{"key":"value","key2":"value2"}`.
    37  	//
    38  	// The `Status` field is optional, and is omitted if the volume driver
    39  	// does not support this feature.
    40  	//
    41  	Status map[string]interface{} `json:"Status,omitempty"`
    42  
    43  	// usage data
    44  	UsageData *VolumeUsageData `json:"UsageData,omitempty"`
    45  }
    46  
    47  // VolumeUsageData volume usage data
    48  // swagger:model VolumeUsageData
    49  type VolumeUsageData struct {
    50  
    51  	// The number of containers referencing this volume.
    52  	// Required: true
    53  	RefCount int64 `json:"RefCount"`
    54  
    55  	// The disk space used by the volume (local driver only)
    56  	// Required: true
    57  	Size int64 `json:"Size"`
    58  }