igneum/relay/clients/IgneumRelayService.xml

59 lines
2.6 KiB
XML

<?xml version="1.0" encoding="UTF-16"?>
<!-- The relay agent's logon task (MF-11, 7 October 2026). install-agent.ps1 fills __USER__ (DOMAIN\user) and
__AGENT_DIR__ (the unzipped client folder) and registers it with schtasks /Create /XML. Runs at that user's logon
in the interactive session (so start-app can open the app window), at the run level the installer chooses (LeastPrivilege
by default: no administrator and no UAC prompt to register or run; -Highest for a PC where elevated tasks must not prompt),
restarted on failure every minute up to 999 times, no time limit, one instance at a time, never stopped for a
battery, started late if the logon was missed. -->
<Task version="1.4" xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task">
<RegistrationInfo>
<Description>Igneum relay agent: polls the relay for signed tasks and can start Igneum Miner; survives the app and a reboot.</Description>
<URI>\IgneumRelayService</URI>
</RegistrationInfo>
<Triggers>
<LogonTrigger>
<Enabled>true</Enabled>
<UserId>__USER__</UserId>
<Delay>PT20S</Delay>
</LogonTrigger>
</Triggers>
<Principals>
<Principal id="Author">
<UserId>__USER__</UserId>
<LogonType>InteractiveToken</LogonType>
<RunLevel>__RUNLEVEL__</RunLevel>
</Principal>
</Principals>
<Settings>
<MultipleInstancesPolicy>IgnoreNew</MultipleInstancesPolicy>
<DisallowStartIfOnBatteries>false</DisallowStartIfOnBatteries>
<StopIfGoingOnBatteries>false</StopIfGoingOnBatteries>
<AllowHardTerminate>true</AllowHardTerminate>
<StartWhenAvailable>true</StartWhenAvailable>
<RunOnlyIfNetworkAvailable>false</RunOnlyIfNetworkAvailable>
<IdleSettings>
<StopOnIdleEnd>false</StopOnIdleEnd>
<RestartOnIdle>false</RestartOnIdle>
</IdleSettings>
<AllowStartOnDemand>true</AllowStartOnDemand>
<Enabled>true</Enabled>
<Hidden>false</Hidden>
<RunOnlyIfIdle>false</RunOnlyIfIdle>
<DisallowStartOnRemoteAppSession>false</DisallowStartOnRemoteAppSession>
<UseUnifiedSchedulingEngine>true</UseUnifiedSchedulingEngine>
<WakeToRun>false</WakeToRun>
<ExecutionTimeLimit>PT0S</ExecutionTimeLimit>
<Priority>7</Priority>
<RestartOnFailure>
<Interval>PT1M</Interval>
<Count>999</Count>
</RestartOnFailure>
</Settings>
<Actions Context="Author">
<Exec>
<Command>powershell.exe</Command>
<Arguments>-NoProfile -ExecutionPolicy Bypass -WindowStyle Hidden -File "__AGENT_DIR__\igneum-agent-service.ps1"</Arguments>
<WorkingDirectory>__AGENT_DIR__</WorkingDirectory>
</Exec>
</Actions>
</Task>