Update vCenter-SSL.ps1
This commit is contained in:
@@ -143,7 +143,7 @@ $CheckSLL = Get-PACertificate -MainDomain $CommonName
|
|||||||
$RUN=$true
|
$RUN=$true
|
||||||
If ((($CheckSLL).AllSANs) -eq $CommonName) {
|
If ((($CheckSLL).AllSANs) -eq $CommonName) {
|
||||||
$daysUntilExpiration = (New-TimeSpan -Start (Get-Date) -End $CheckSLL.NotAfter).Days
|
$daysUntilExpiration = (New-TimeSpan -Start (Get-Date) -End $CheckSLL.NotAfter).Days
|
||||||
If ($daysUntilExpiration -lt 300) {
|
If ($daysUntilExpiration -lt 30) {
|
||||||
Write-Host "Renewing cert for '$("$CommonName")' " -ForegroundColor Yellow
|
Write-Host "Renewing cert for '$("$CommonName")' " -ForegroundColor Yellow
|
||||||
Submit-Renewal $CommonName
|
Submit-Renewal $CommonName
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user