New-ServiceFabricPackageSharingPolicy

Creates a package sharing policy.

Syntax

New-ServiceFabricPackageSharingPolicy
   [[-PackageName] <String>]
   [-SharingScopeAll]
   [-TimeoutSec <Int32>]
   [<CommonParameters>]
New-ServiceFabricPackageSharingPolicy
   [[-PackageName] <String>]
   [-SharingScopeCode]
   [-TimeoutSec <Int32>]
   [<CommonParameters>]
New-ServiceFabricPackageSharingPolicy
   [[-PackageName] <String>]
   [-SharingScopeConfig]
   [-TimeoutSec <Int32>]
   [<CommonParameters>]
New-ServiceFabricPackageSharingPolicy
   [[-PackageName] <String>]
   [-SharingScopeData]
   [-TimeoutSec <Int32>]
   [<CommonParameters>]

Description

The New-ServiceFabricPackageSharingPolicy cmdlet creates a package sharing policy. You can pass a PackageSharingPolicy object to the Copy-ServiceFabricServicePackageToNode cmdlet.

To manage Service Fabric clusters, start Windows PowerShell by using the Run as administrator option. Before you perform any operation on a Service Fabric cluster, establish a connection to the cluster by using the Copy-ServiceFabricServicePackageToNode cmdlet.

Parameters

-PackageName

Specifies the name of the package that to share.

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

-SharingScopeAll

Indicates that this cmdlet uses All as the package sharing scope. The All scope shares all code, config, and data packages from the service manifest.

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

-SharingScopeCode

Indicates that this cmdlet uses Code as the package sharing scope. The Code scope shares all code packages from the service manifest.

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

-SharingScopeConfig

Indicates that this cmdlet uses Config as the package sharing scope. The Config scope shares all config packages from the service manifest.

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

-SharingScopeData

Indicates that this cmdlet uses Data as the package sharing scope. The Data scope shares all data packages from the service manifest.

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

-TimeoutSec

Specifies the time-out period, in seconds, for the operation.

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

Inputs

None

Outputs

System.Object