diff --git a/Makefile b/Makefile index 76d43dd..c9fe1f0 100644 --- a/Makefile +++ b/Makefile @@ -39,17 +39,17 @@ go-compile: # MacOS #GOOS=darwin GOARCH=386 go build $(LDFLAGS) -o bin/main-darwin-386 -tags "release" cmd/distribyted/main.go # Linux - GOOS=linux GOARCH=386 go build $(LDFLAGS) -o bin/main-linux-386 -tags "release" cmd/distribyted/main.go + GOOS=linux GOARCH=386 go build $(LDFLAGS) -o bin/distribyted-linux-386 -tags "release" cmd/distribyted/main.go # 64-Bit # FreeBDS #GOOS=freebsd GOARCH=amd64 go build $(LDFLAGS) -o bin/main-freebsd-amd64 -tags "release" cmd/distribyted/main.go # MacOS #GOOS=darwin GOARCH=amd64 go build $(LDFLAGS) -o bin/main-darwin-amd64 -tags "release" cmd/distribyted/main.go # Linux - GOOS=linux GOARCH=amd64 go build $(LDFLAGS) -o bin/main-linux-amd64 -tags "release" cmd/distribyted/main.go + GOOS=linux GOARCH=amd64 go build $(LDFLAGS) -o bin/distribyted-linux-amd64 -tags "release" cmd/distribyted/main.go # ARM - GOOS=linux GOARCH=arm GOARM=5 go build $(LDFLAGS) -o bin/main-linux-arm -tags "release" cmd/distribyted/main.go + GOOS=linux GOARCH=arm GOARM=5 go build $(LDFLAGS) -o bin/distribyted-linux-arm -tags "release" cmd/distribyted/main.go .PHONY: help all: help diff --git a/cmd/distribyted/main.go b/cmd/distribyted/main.go index f3c4686..e6e36c8 100644 --- a/cmd/distribyted/main.go +++ b/cmd/distribyted/main.go @@ -136,11 +136,14 @@ func main() { ctx.JSON(200, stats) }) + log.WithField("host", "0.0.0.0:4444").Info("starting webserver") + //TODO add port from configuration if err := r.Run(":4444"); err != nil { log.WithError(err).Error("error initializing server") return } + } func tryClose(log *logrus.Logger, c *torrent.Client, mountService *mount.Handler) { diff --git a/mount/handler.go b/mount/handler.go index 71be5f1..c44c3ca 100644 --- a/mount/handler.go +++ b/mount/handler.go @@ -58,7 +58,7 @@ func (s *Handler) Mount(mpc *config.MountPoint) error { } s.s.Add(mpc.Path, t) - log.WithField("name", t.Name()).Info("torrent added") + log.WithField("name", t.Name()).WithField("path", mpc.Path).Info("torrent added to mountpoint") torrents = append(torrents, t) }