Files
html/products/install-sentinel.bat
2026-04-12 22:57:03 +02:00

40 lines
1.7 KiB
Batchfile

@echo off
title WEVAL Sentinel v2 — Auto-Install
echo ========================================
echo WEVAL SENTINEL v2.0 — AUTO INSTALLER
echo ========================================
echo.
:: Create directory
if not exist "C:\ProgramData\WEVAL" mkdir "C:\ProgramData\WEVAL"
:: Kill old sentinel if running
echo [1/5] Stopping old agent...
taskkill /F /FI "WINDOWTITLE eq WEVAL Sentinel*" >nul 2>&1
powershell -Command "Get-Process powershell | Where-Object {$_.MainWindowTitle -like '*sentinel*'} | Stop-Process -Force" >nul 2>&1
:: Copy new agent from git repo
echo [2/5] Installing Sentinel v2...
copy /Y "%~dp0products\weval-sentinel-agent.ps1" "C:\ProgramData\WEVAL\sentinel-agent.ps1" >nul
:: Create scheduled task for auto-start at logon
echo [3/5] Setting auto-start...
schtasks /Delete /TN "WEVAL Sentinel" /F >nul 2>&1
schtasks /Create /TN "WEVAL Sentinel" /TR "powershell.exe -ExecutionPolicy Bypass -WindowStyle Hidden -File C:\ProgramData\WEVAL\sentinel-agent.ps1" /SC ONLOGON /RL HIGHEST /F >nul
:: Start agent now
echo [4/5] Launching Sentinel v2...
start "WEVAL Sentinel v2" powershell.exe -ExecutionPolicy Bypass -File "C:\ProgramData\WEVAL\sentinel-agent.ps1"
:: Verify
echo [5/5] Verifying...
timeout /t 3 >nul
powershell -Command "if (Get-Process powershell -ErrorAction SilentlyContinue | Where-Object {$_.MainWindowTitle -like '*Sentinel*'}) { Write-Host '[OK] Sentinel v2 running' -ForegroundColor Green } else { Write-Host '[!] Check manually' -ForegroundColor Yellow }"
echo.
echo ========================================
echo DONE — Blade is now part of WEVAL mesh
echo Dashboard: https://weval-consulting.com/blade-center.html
echo ========================================
pause