From 79b2cf15c8d563dc5a3ea589ea1c4a29ee1315e8 Mon Sep 17 00:00:00 2001 From: "kali kaneko (leap communications)" Date: Thu, 27 Feb 2020 18:06:22 +0100 Subject: [feat] listen on available port --- pkg/helper/windows_service.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'pkg/helper/windows_service.go') diff --git a/pkg/helper/windows_service.go b/pkg/helper/windows_service.go index b35ba19..82f6e2b 100644 --- a/pkg/helper/windows_service.go +++ b/pkg/helper/windows_service.go @@ -8,8 +8,6 @@ package helper import ( "fmt" - //"strings" - //"time" "golang.org/x/sys/windows/svc" "golang.org/x/sys/windows/svc/debug" @@ -24,8 +22,7 @@ func (m *myservice) Execute(args []string, r <-chan svc.ChangeRequest, changes c const cmdsAccepted = svc.AcceptStop | svc.AcceptShutdown | svc.AcceptPauseAndContinue changes <- svc.Status{State: svc.StartPending} changes <- svc.Status{State: svc.Running, Accepts: cmdsAccepted} - // TODO use httpBindAddr - go runCommandServer("localhost:7171") + go runCommandServer(httpBindAddr) loop: for { select { -- cgit v1.2.3