This commit is contained in:
Henrique Dias committed 2015-09-27 20:50:17 +01:00
1 parent 34d72cbbc9
commit 1d9584345e
3 files changed
+5 -4

No files matched your search

+2 -1
View File
@@ -2,6 +2,7 @@ package utils
import (
"errors"
"fmt"
"io"
"log"
"net/http"
@@ -163,9 +164,9 @@ func ParseComponents(r *http.Request) []string {
func Run(c *config.Config) {
if c.Command != "" {
out, err := exec.Command(c.Command, c.Args...).Output()
fmt.Print(string(out))
if err != nil {
log.Panic("Can't execute the commands defined on Caddyfile.")
log.Print(out)
}
return