diff --git a/main.go b/main.go index a38067ab758c287121d4baab28ff8b68052b8d1e..57787e41e521345b4d73794dd7eec2eb578d5bdf 100644 --- a/main.go +++ b/main.go @@ -72,7 +72,7 @@ func triggerPuppet(w http.ResponseWriter, req *http.Request) { cmd := exec.Command("/usr/bin/pkill", "-f", "/opt/puppetlabs/puppet/bin/puppet", "-s", "SIGUSR1") authToken := strings.Split(req.Header.Get("Authorization"), "Bearer ")[1] statusFile := "/tmp/200.json" - + fmt.Fprintf(w, "Welcome, "+authToken+"\r\n") // create json files on the fly okMsg := []byte("{\n \"status\": \"OK\",\n \"response\": 200\n }") koMsg := []byte("{\n \"status\": \"KO\",\n \"response\": 503\n }")