Take control over your live stream video by running it yourself. Streaming + chat out of the box.
HTML activitypubbroadcastingchatdecentralizedfederationfediversegolanghacktoberfesthlslivelivestreamowncastrtmpself-hostedstreaming-videovideo
Standardize logging format
Gabe Kangase3d84f37ac3f
diff --git a/config.go b/config.goindex 97c917c5a4..3049ead34d 100644--- a/config.go+++ b/config.go@@ -3,7 +3,8 @@ package mainimport ("fmt""io/ioutil"- "log"++ log "github.com/sirupsen/logrus""gopkg.in/yaml.v2")diff --git a/ffmpeg.go b/ffmpeg.goindex 8c91492f9b..e11a01c00d 100644--- a/ffmpeg.go+++ b/ffmpeg.go@@ -2,13 +2,14 @@ package mainimport ("fmt"- "log""math""os""os/exec""path""strconv""strings"++ log "github.com/sirupsen/logrus")func showStreamOfflineState(configuration Config) {diff --git a/handler.go b/handler.goindex 6aad7f0eff..443de24b29 100644--- a/handler.go+++ b/handler.go@@ -3,10 +3,11 @@ package mainimport ("bytes""io"- "log""os""syscall"+ log "github.com/sirupsen/logrus"+"github.com/pkg/errors""github.com/yutopp/go-flv"flvtag "github.com/yutopp/go-flv/tag"diff --git a/playlistMonitor.go b/playlistMonitor.goindex beab03c10e..5cd68d7671 100644--- a/playlistMonitor.go+++ b/playlistMonitor.go@@ -1,7 +1,6 @@package mainimport (- "fmt""io/ioutil""path""path/filepath"@@ -62,7 +61,7 @@ func updateVariantPlaylist(fullPath string) {playlistBytes, err := ioutil.ReadFile(fullPath)verifyError(err)playlistString := string(playlistBytes)- fmt.Println("Rewriting playlist", relativePath, "to", path.Join(configuration.PublicHLSPath, relativePath))+ // fmt.Println("Rewriting playlist", relativePath, "to", path.Join(configuration.PublicHLSPath, relativePath))playlistString = storage.GenerateRemotePlaylist(playlistString, variant)@@ -79,7 +78,7 @@ func monitorVideoContent(pathToMonitor string, configuration Config, storage Chu} else {variants[0] = Variant{0, make([]Segment, 0)}}- log.Printf("Using directory %s for storing files with %d variants...\n", pathToMonitor, len(variants))+ // log.Printf("Using directory %s for storing files with %d variants...\n", pathToMonitor, len(variants))w := watcher.New()@@ -114,7 +113,7 @@ func monitorVideoContent(pathToMonitor string, configuration Config, storage Chu}()newObjectPath := <-newObjectPathChannelsegment.RemoteID = newObjectPath- fmt.Println("Uploaded", segment.RelativeUploadPath, "as", newObjectPath)+ // fmt.Println("Uploaded", segment.RelativeUploadPath, "as", newObjectPath)variants[segment.VariantIndex].Segments = append(variants[segment.VariantIndex].Segments, segment)diff --git a/server.go b/server.goindex ca43df07c2..4d4e63c595 100644--- a/server.go+++ b/server.go@@ -2,10 +2,11 @@ package mainimport ("fmt"- "log""net/http""time"+ log "github.com/sirupsen/logrus"+"golang.org/x/net/websocket")diff --git a/stats.go b/stats.goindex 7032ca5a10..bc8fb9d217 100644--- a/stats.go+++ b/stats.go@@ -11,10 +11,11 @@ package mainimport ("encoding/json""io/ioutil"- "log""math""os""time"++ log "github.com/sirupsen/logrus")type Stats struct {