Commit 50009052 authored by 李世星's avatar 李世星

fix(优化时区问题): 202302151643

parent ad446204
Pipeline #16350 passed with stage
in 0 seconds
...@@ -6,6 +6,7 @@ import ( ...@@ -6,6 +6,7 @@ import (
"io" "io"
"log" "log"
"os" "os"
"time"
"github.com/y7ut/logtransfer/transfer" "github.com/y7ut/logtransfer/transfer"
) )
...@@ -34,5 +35,9 @@ func main() { ...@@ -34,5 +35,9 @@ func main() {
log.Default().SetFlags(log.LstdFlags) log.Default().SetFlags(log.LstdFlags)
log.Default().SetOutput(io.MultiWriter(writerLog, os.Stderr)) log.Default().SetOutput(io.MultiWriter(writerLog, os.Stderr))
//设置时间东八区
cstZone := time.FixedZone("CST", 8*3600)
time.Local = cstZone
transfer.Run(*c) transfer.Run(*c)
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment