## Description: Script de d�marrage EASY ## Fonctionnement: Toutes les 60, 5 services EASY d�marrent ## Version: 0.1 ## Auteur: Benoit MENARD ## ============== HISTORIQUE DES VERSIONS ## ============== . ${PSScriptRoot}\pslib.ps1 Start-Log "${PSScriptRoot}\startup.log" Write-LogInfo "Début" $InformationPreference = "Continue" $Svcs = Get-Service -Name "EASY*" Write-LogInfo ("{0} services trouvés" -f $Svcs.Count) $Cpt = 0 Foreach ($Svc in $Svcs) { Write-LogInfo ("{0} démarrage" -f $Svc.Name) If ($Svc.Status -eq "Running") { Write-LogWarn ("{0} déja en cours" -f $Svc.Name) } else { Start-Service $Svc } $Cpt ++ If ($Cpt % 5 -eq 0) { #Multiple de 5 Start-Sleep -Seconds 60 Write-LogInfo "Attente 60s" } }