virtualharddisk

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2025 License: Apache-2.0 Imports: 12 Imported by: 1

Documentation

Overview

Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the Apache v2.0 License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type VirtualHardDiskClient

type VirtualHardDiskClient struct {
	storage.BaseClient
	// contains filtered or unexported fields
}

Client structure

func NewVirtualHardDiskClient

func NewVirtualHardDiskClient(cloudFQDN string, authorizer auth.Authorizer) (*VirtualHardDiskClient, error)

NewClient method returns new client

func (*VirtualHardDiskClient) CreateOrUpdate

func (c *VirtualHardDiskClient) CreateOrUpdate(ctx context.Context, group, container, name string, storage *storage.VirtualHardDisk) (*storage.VirtualHardDisk, error)

CreateOrUpdate methods invokes create or update on the client

func (*VirtualHardDiskClient) Delete

func (c *VirtualHardDiskClient) Delete(ctx context.Context, group, container, name string) error

Delete methods invokes delete of the storage resource

func (*VirtualHardDiskClient) DownloadVhdFromHttp added in v0.22.1

func (c *VirtualHardDiskClient) DownloadVhdFromHttp(ctx context.Context, group, container, name string, storage *storage.VirtualHardDisk, azHttpImg *compute.AzureGalleryImageProperties) (*storage.VirtualHardDisk, error)

func (*VirtualHardDiskClient) Get

func (c *VirtualHardDiskClient) Get(ctx context.Context, group, container, name string) (*[]storage.VirtualHardDisk, error)

Get methods invokes the client Get method

func (*VirtualHardDiskClient) Hydrate added in v0.25.1

func (c *VirtualHardDiskClient) Hydrate(ctx context.Context, group, container, name string, storage *storage.VirtualHardDisk) (*storage.VirtualHardDisk, error)

The entry point for the hydrate call takes the group name, container name and the name of the disk file. The group is standard input for every call. Ultimately, we need the full path on disk to the disk file which we assemble from the path of the container plus the file name of the disk. (e.g. "C:\ClusterStorage\Userdata_1\abc123" for the container path and "my_disk.vhd" for the disk name)

func (*VirtualHardDiskClient) Precheck added in v0.19.1

func (c *VirtualHardDiskClient) Precheck(ctx context.Context, group, container string, vhds []*storage.VirtualHardDisk) (bool, error)

Prechecks whether the system is able to create specified virtual hard disks. Returns true with virtual hard disk placement in mapping from virtual hard disk names to container names; or false with reason in error message.

func (*VirtualHardDiskClient) Resize

func (c *VirtualHardDiskClient) Resize(ctx context.Context, group, container, name string, newSize int64) error

Resize methods invokes Update to change size of the storage resource

func (*VirtualHardDiskClient) Upload added in v0.25.3

func (c *VirtualHardDiskClient) Upload(ctx context.Context, group, container, name string, targetUrl string) error

Upload methods invokes upload of the storage resource to target sasurl

Jump to

Keyboard shortcuts

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