Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrContainerNotFound = errors.New("container not found")
)
Functions ¶
func NewBlobSdkClient ¶
func NewBlobSdkClient( credentialProvider auth.MultiTenantCredentialProvider, accountConfig *AccountConfig, userConfigManager config.UserConfigManager, coreClientOptions *azcore.ClientOptions, cloud *cloud.Cloud, tenantResolver account.SubscriptionTenantResolver, ) (*azblob.Client, error)
createClient creates a new blob client and caches it for future use
Types ¶
type AccountConfig ¶
type AccountConfig struct {
AccountName string
ContainerName string
Endpoint string
SubscriptionId string
}
AccountConfig contains the configuration for connecting to a storage account
type BlobClient ¶
type BlobClient interface {
// Download downloads a blob from the configured storage account container.
Download(ctx context.Context, blobPath string) (io.ReadCloser, error)
// Upload uploads a blob to the configured storage account container.
Upload(ctx context.Context, blobPath string, reader io.Reader) error
// Delete deletes a blob from the configured storage account container.
Delete(ctx context.Context, blobPath string) error
// Items returns a list of blobs in the configured storage account container.
Items(ctx context.Context) ([]*Blob, error)
}
func NewBlobClient ¶
func NewBlobClient( config *AccountConfig, client *azblob.Client, ) BlobClient
NewBlobClient creates a new BlobClient instance to manage blobs within a container.
type FileShareService ¶
type FileShareService interface {
UploadPath(ctx context.Context, subId, shareUrl, source string) error
}
func NewFileShareService ¶
func NewFileShareService( accountCreds account.SubscriptionCredentialProvider, options *arm.ClientOptions, ) FileShareService
Click to show internal directories.
Click to hide internal directories.