Set-SCApplicationPackage

Modifies the properties of an application package.

Syntax

Set-SCApplicationPackage [-ApplicationPackage] <ApplicationPackage[]> [-Description <String>]
 [-Enabled <Boolean>] [-EncryptionKey <PSCredential>] [-FamilyName <String>] [-JobVariable <String>]
 [-Name <String>] [-Owner <String>] [-PROTipID <Guid>] [-Release <String>] [-RunAsynchronously]
 [-SharePath <String>] [-UserRole <UserRole>] [-VMMServer <ServerConnection>] [<CommonParameters>]
Set-SCApplicationPackage [-ApplicationPackage] <ApplicationPackage[]> -FamilyName <String>
 [-JobVariable <String>] [-PROTipID <Guid>] -Release <String> [-RunAsynchronously] [-SetAsEquivalent]
 [-VMMServer <ServerConnection>] [<CommonParameters>]

Description

The Set-SCApplicationPackage cmdlet modifies the properties of an application package stored in the Virtual Machine Manager (VMM) library.

Examples

Example 1: Update the description for an application package

PS C:\> $AppPackage = Get-SCApplicationPackage -Name "WebApp01.zip"
PS C:\> Set-SCApplicationPackage -ApplicationPackage $AppPackage -Description "Web application to install on a service."

The first command gets the application package object named WebApp01.zip and stores the object in the $AppPackage variable.

The second command updates the description for WebApp01.zip.

Parameters

-ApplicationPackage

Specifies an array of application package objects.

Type:ApplicationPackage[]
Required:True
Position:0
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-Description

States a description for the specified object.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Enabled

Enables an object when set to $True, or disables an object when set to $False. For example, if you want to upgrade software on a virtual machine template, you can disable the template object in the VMM library to temporarily prevent users from using that object.

Type:Boolean
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-EncryptionKey

Specifies credentials to be used as an encryption key when you add a Hyper-V host located in a perimeter network to VMM.

Example format: -SecurityFile "C:\SecurityFile.txt" -EncryptionKey $Key

Type:PSCredential
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-FamilyName

Specifies a family name for a physical resource in the VMM library. This value is used in conjunction with Release, Namespace, and Type to establish equivalency among library resources.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-JobVariable

Specifies that job progress is tracked and stored in the variable named by this parameter.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Name

Specifies the name of a VMM object.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Owner

Specifies the owner of a VMM object in the form of a valid domain user account.

- Example format: -Owner "Contoso\PattiFuller"

  • Example format: -Owner "PattiFuller@Contoso"

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PROTipID

Specifies the ID of the Performance and Resource Optimization tip (PRO tip) that triggered this action. This parameter lets you audit PRO tips.

Type:Guid
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Release

Specifies a string that describes the release of a library resource. VMM automatically creates a release value for every resource imported into the library. After the resource has been imported, the string can be customized.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RunAsynchronously

Indicates that the job runs asynchronously so that control returns to the command shell immediately.

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

Indicates that the cmdlet marks multiple application packages as equivalent.

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

Specifies a path to a valid library share on an existing library server that uses a Universal Naming Convention (UNC) path.

Example format: -SharePath "\\LibServer01\LibShare"

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-UserRole

Specifies a user role object.

Type:UserRole
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VMMServer

Specifies a VMM server object.

Type:ServerConnection
Required:False
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False

Outputs

ApplicationPackage

This cmdlet returns an **ApplicationPackage** object.