Export (0) Print
Expand All

Set-AzureStorageContainerAcl

[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

Set-AzureStorageContainerAcl

Sets the public access permission to a storage container.

 

Parameter Set: Default
Set-AzureStorageContainerAcl [-Name] <String> [-Permission] <String> [-Context <AzureStorageContext> ] [-PassThru] [ <CommonParameters>]




 

This topic describes the cmdlet in the .6.19 version of the Windows Azure PowerShell module. To find out the version of the module you're using, from the Windows Azure PowerShell console, type (get-module azure).version.

Set the public access permission to the specified storage container in Windows Azure.

 

-Context<AzureStorageContext>

Specifies the Windows Azure storage context. You can create it by using the New-AzureStorageContext cmdlet.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-Name<String>

Container name.


Aliases

N,Container

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue, ByPropertyName)

Accept Wildcard Characters?

false

-PassThru

Output the specified container.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Permission<String>

Defines the level of public access to this container. By default, the container and any blobs within it are accessible only by the owner of the storage account. To grant anonymous users with read permissions to a container and its blobs, you can set the container permissions to allow public access. Anonymous users can read blobs within a publicly accessible container without authenticating the request. Allowed values are:

--Container, which provides full read access to a container and its blobs. Clients can enumerate blobs within the container through anonymous request, but cannot enumerate containers within the storage account.

--Blob, which provides read access to blob data within a container through anonymous request, but does not provide access to container data. Clients cannot enumerate blobs within the container via anonymous request.

--Off, which restricts access to only the storage account owner.


Aliases

PublicAccess

Required?

true

Position?

2

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see  about_CommonParameters (http://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

 

Example 1

This example creates a container with no public access.


C:\PS>Set-AzureStorageContainerAcl -Container container1 -Permission off -PassThru

Example 2

This example gets all storage containers whose name starts with ‘container’ and then passes the result on the pipeline to set the permission for all of them to Blob access.


C:\PS>Get-AzureStorageContainer container* | Set-AzureStorageContainerAcl -Permission blob -PassThru

Related topics

Show:
© 2014 Microsoft