diff --git a/app/user_center/rpc/user_center.go b/app/user_center/rpc/user_center.go index a0d155e..68101b0 100644 --- a/app/user_center/rpc/user_center.go +++ b/app/user_center/rpc/user_center.go @@ -12,6 +12,8 @@ import ( "live-service/app/user_center/rpc/internal/svc" "live-service/app/user_center/rpc/pb" "live-service/common/interceptor/rpcserver" + "os" + "path/filepath" "github.com/zeromicro/go-zero/core/service" "github.com/zeromicro/go-zero/zrpc" @@ -30,6 +32,11 @@ func main() { var cg config.GameConfig config.MustLoad(*configFile, &cg) + err := os.Setenv("ZONEINFO", filepath.Join("./", "zoneinfo.zip")) + if err != nil { + panic(err) + } + ctx := svc.NewServiceContext(&c, &cg) svr := server.NewUserCenterServer(ctx)