編輯

共用方式為


Set-AzStorageSyncCloudEndpointPermission

This command sets RBAC permission required for an Azure File Sync cloud endpoint in a sync group.

Syntax

Set-AzStorageSyncCloudEndpointPermission
   [-ResourceGroupName] <String>
   [-StorageSyncServiceName] <String>
   [-SyncGroupName] <String>
   -Name <String>
   [-AsJob]
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
Set-AzStorageSyncCloudEndpointPermission
   [-ParentObject] <PSSyncGroup>
   -Name <String>
   [-AsJob]
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
Set-AzStorageSyncCloudEndpointPermission
   [-ParentResourceId] <String>
   -Name <String>
   [-AsJob]
   [-DefaultProfile <IAzureContextContainer>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

This command sets RBAC permission required for an Azure File Sync cloud endpoint in a sync group. This permission allow Azure file sync to access storage account and azure file share for performing sync operations.

Examples

Example 1

Set-AzStorageSyncCloudEndpointPermission -ResourceGroupName "myResourceGroup" -StorageSyncServiceName "myStorageSyncServiceName" -SyncGroupName "mySyncGroupName" -Name "myCloudEndpointName"

A cloud endpoint permission is an integral access requirement for a sync group, this is an example of ensuring all required permissions required for existing sync group called "mySyncGroupName".

Parameters

-AsJob

Run cmdlet in the background

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with Azure.

Type:IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Name

Name of the cloud endpoint. When created through the Azure portal, Name is set to the name of the Azure file share it references.

Type:String
Aliases:CloudEndpointName
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-ParentObject

SyncGroup Object, normally passed through the parameter.

Type:PSSyncGroup
Aliases:SyncGroup
Position:0
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-ParentResourceId

SyncGroup Parent Resource Id

Type:String
Aliases:SyncGroupId
Position:0
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-ResourceGroupName

Resource Group Name.

Type:String
Position:0
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-StorageSyncServiceName

Name of the StorageSyncService.

Type:String
Aliases:ParentName
Position:1
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-SyncGroupName

Name of the SyncGroup.

Type:String
Position:2
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

PSSyncGroup

String

Outputs

PSCloudEndpoint