added bat files to install and uninstall DDNSUpdater as Service
This commit is contained in:
parent
015755710a
commit
f50ae19805
17
bin/install_ddnsupdater_service.bat
Normal file
17
bin/install_ddnsupdater_service.bat
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
@echo off
|
||||||
|
REM Check if a path parameter was provided
|
||||||
|
IF "%~1"=="" (
|
||||||
|
echo Usage: install_ddns_service.bat ^<path_to_exe^>
|
||||||
|
exit /b 1
|
||||||
|
)
|
||||||
|
|
||||||
|
SET EXE_PATH=%~1
|
||||||
|
|
||||||
|
REM Create the service (auto-start)
|
||||||
|
sc create DDNSUpdaterService binPath= "%EXE_PATH%" start= auto
|
||||||
|
|
||||||
|
REM Start the service
|
||||||
|
sc start DDNSUpdaterService
|
||||||
|
|
||||||
|
echo Service DDNSUpdaterService installed and started.
|
||||||
|
pause
|
||||||
5
bin/uninstall_ddnsupdater_service.bat
Normal file
5
bin/uninstall_ddnsupdater_service.bat
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
@echo off
|
||||||
|
sc stop DDNSUpdaterService
|
||||||
|
sc delete DDNSUpdaterService
|
||||||
|
echo Service DDNSUpdaterService stopped and deleted.
|
||||||
|
pause
|
||||||
Loading…
Reference in New Issue
Block a user