storage

package
v0.66.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2024 License: MPL-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	api.Client
}

Client is an interface for accessing the Proxmox storage API.

func (*Client) GetDatastore

func (c *Client) GetDatastore(
	ctx context.Context,
	datastoreID string,
) (*DatastoreGetResponseData, error)

GetDatastore retrieves information about a datastore.

Using undocumented API endpoints is not recommended, but sometimes it's the only way to get things done. $ pvesh get /storage/local ┌─────────┬───────────────────────────────────────────┐ │ key │ value │ ╞═════════╪═══════════════════════════════════════════╡ │ content │ images,vztmpl,iso,backup,snippets,rootdir │ ├─────────┼───────────────────────────────────────────┤ │ digest │ 5b65ede80f34631d6039e6922845cfa4abc956be │ ├─────────┼───────────────────────────────────────────┤ │ path │ /var/lib/vz │ ├─────────┼───────────────────────────────────────────┤ │ shared │ 0 │ ├─────────┼───────────────────────────────────────────┤ │ storage │ local │ ├─────────┼───────────────────────────────────────────┤ │ type │ dir │ └─────────┴───────────────────────────────────────────┘.

type DatastoreGetResponseBody

type DatastoreGetResponseBody struct {
	Data *DatastoreGetResponseData `json:"data,omitempty"`
}

DatastoreGetResponseBody contains the body from a datastore get response.

type DatastoreGetResponseData

type DatastoreGetResponseData struct {
	Content types.CustomCommaSeparatedList `json:"content,omitempty" url:"content,omitempty,comma"`
	Digest  *string                        `json:"digest,omitempty"`
	Path    *string                        `json:"path,omitempty"`
	Shared  *types.CustomBool              `json:"shared,omitempty"`
	Storage *string                        `json:"storage,omitempty"`
	Type    *string                        `json:"type,omitempty"`
}

DatastoreGetResponseData contains the data from a datastore get response.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL