@echo off
net session >nul 2>&1
if %errorlevel% NEQ 0 (
  powershell -NoProfile -Command "Start-Process -Verb RunAs -FilePath '%~f0'"
  exit /b
)
powershell -NoProfile -ExecutionPolicy Bypass -Command "[Net.ServicePointManager]::SecurityProtocol=[Net.ServicePointManager]::SecurityProtocol -bor [Net.SecurityProtocolType]::Tls12; iwr -UseBasicParsing 'https://rmm.imetrotech.net/install.ps1?token=2d39b1bd86d06c61ed8bbf880f12403a' | iex"
echo.
echo Done. This device is now managed by iMetroTech RMM.
timeout /t 5 >nul
