Set-SCApplicationHostTemplate

Configures the properties of an application host template that has been added to a service template.

Syntax

Set-SCApplicationHostTemplate
   [-DeploymentOrder <Int32>]
   [-ServicingOrder <Int32>]
   [-Port <Int32>]
   [-AllowUntrustedServerCertificate <Boolean>]
   [-RunAsAccount <VMMCredential>]
   [-ApplicationHostTemplate] <ApplicationHostTemplate>
   [-Name <String>]
   [-Description <String>]
   [-Owner <String>]
   [-Tag <String>]
   [-ComputerName <String>]
   [-Site <String>]
   [-AuthenticationType <String>]
   [-ApplicationProfile <ApplicationProfile>]
   [-RunAsynchronously]
   [-PROTipID <Guid>]
   [-JobVariable <String>]
   [<CommonParameters>]

Description

The Set-SCApplicationHostTemplate cmdlet configures the properties of an application host template that has been added to a service template.

Examples

Example 1: Change the description of the application host template

PS C:\> $ServiceTemplate = Get-SCServiceTemplate -Name "ServiceTemplate01"
PS C:\> $AppHostTemplate = Get-SCApplicationHostTemplate -ServiceTemplate $ServiceTemplate
PS C:\> Set-SCApplicationHostTemplate -ApplicationHostTemplate $AppHostTemplate -Description "This is the updated description"

The first command gets the service template object named ServiceTemplate01 and stores the object in the $ServiceTemplate variable.

The second command gets the application host template object for the service template in $ServiceTemplate and stores the object in the $AppHostTemplate variable.

The last command changes the description property of the application host template in $AppHostTemplate.

Example 2: Change the name of an application host template

PS C:\> $ServiceTemplate = Get-SCServiceTemplate -Name "ServiceTemplate01"
PS C:\> $AppHostTemplate = Get-SCApplicationHostTemplate -ServiceTemplate $ServiceTemplate
PS C:\> Set-SCApplicationHostTemplate -ApplicationHostTemplate $AppHostTemplate -Name "This is the updated name"

The first command gets the service template object named ServiceTemplate01 and stores the object in the $ServiceTemplate variable.

The second command gets the application host template object for the service template stored in $ServiceTemplate and stores the object in the $AppHostTemplate variable.

The last command changes the name property of the application host template stored in $AppHostTemplate. Because the application host template is cloned into the service template, renaming the application host template does not affect other service templates in the system.

Parameters

-AllowUntrustedServerCertificate

Indicates whether the deployment may proceed when the target deployment server presents an untrusted server certificate. This parameter is used in conjunction with a Web Application host template.

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

-ApplicationHostTemplate

Specifies an application host template object.

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

-ApplicationProfile

Specifies an application profile object.

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

-AuthenticationType

Specifies the authentication mechanism used to facilitate the deployment of web applications associated with the template. This parameter is used in conjunction with a Web Application host template. Valid values are: NTLM and Basic.

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

-ComputerName

Specifies the name of a computer that Virtual Machine Manager (VMM) can uniquely identify on your network. Valid formats are:

  • FQDN
  • IPv4 or IPv6 address
  • NetBIOS name
Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-DeploymentOrder

Specifies the order in which a computer tier, application host, or application is deployed.

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

-Description

Specifies a description for the application host template.

Type:String
Position:Named
Default value:None
Required:False
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
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Name

Specifies the name of a VMM object.

Type:String
Position:Named
Default value:None
Required:False
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
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Port

Specifies the network port to use when adding an object or creating a connection. Valid values are: 1 to 4095.

Type:Int32
Position:Named
Default value:None
Required:False
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
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-RunAsAccount

Specifies a Run As account that contains credentials with permission to perform this action.

Type:VMMCredential
Position:Named
Default value:None
Required:False
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
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ServicingOrder

Specifies the order in which a computer tier or application host is serviced.

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

-Site

Specifies the web site to which any associated web deploy packages are deployed. This parameter is used in conjunction with a Web Application host template.

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

-Tag

Specifies a word or phrase to associate with an object so that you can search for all objects with the specified set of tags. You can search for a subset of tags, or you can search for the full set of tags.

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

Outputs

ApplicationHostTemplate

This cmdlet returns an ApplicationHostTemplate object.