22 lines
1.1 KiB
PowerShell
22 lines
1.1 KiB
PowerShell
function New-AppTierApplicationPools {
|
|
<#
|
|
.SYNOPSIS
|
|
This function sets the application tier application pools.
|
|
TODO: This function should be deprecated as of April 2021
|
|
#>
|
|
[CmdletBinding()]
|
|
Param()
|
|
|
|
foreach ($appPool in $global:appTierApplications) {
|
|
## When we can get the bootstrap value set for Get-AppServiceAccountName we can remove this if block
|
|
## TODO: cbrand ~ when https://jira.alkami.com/browse/SRE-12325 is completed we should remove this
|
|
if ([string]::IsNullOrWhiteSpace((Get-AppSetting "Environment.UserPrefix" -SuppressWarnings))) {
|
|
## TODO: cbrand - 2019-08-19 - Replace the -Credential parameter with a call to (Get-AppServiceAccountName $appPool.WebAppName) or just embed that lookup in the call below if everything will be a GMSAAccount.
|
|
New-AppTierApplicationPool -AppPoolName $appPool.WebAppName -Credential (Get-AlkamiCredential $appPool.User $appPool.Password) -IsGMSAAccount:$appPool.IsGMSAAccount
|
|
} else {
|
|
New-AlkamiWebAppPool -appPoolName $appPool.WebAppName
|
|
}
|
|
}
|
|
}
|
|
|
|
Set-Alias -name Create-AppTierApplicationPools -value New-AppTierApplicationPools; |