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.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
0
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
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.
Parameter properties
Type:
SwitchParameter
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
All
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-SharingScopeCode
Indicates that this cmdlet uses Code as the package sharing scope.
The Code scope shares all code packages from the service manifest.
Parameter properties
Type:
SwitchParameter
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
Code
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-SharingScopeConfig
Indicates that this cmdlet uses Config as the package sharing scope.
The Config scope shares all config packages from the service manifest.
Parameter properties
Type:
SwitchParameter
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
Config
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-SharingScopeData
Indicates that this cmdlet uses Data as the package sharing scope.
The Data scope shares all data packages from the service manifest.
Parameter properties
Type:
SwitchParameter
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
Data
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-TimeoutSec
Specifies the time-out period, in seconds, for the operation.
Parameter properties
Type:
Int32
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters.