♻️ Move models.Account to sec.UserInfo

This commit is contained in:
2024-10-30 23:26:13 +08:00
parent 14baee03fe
commit 8fbb79607b
38 changed files with 346 additions and 272 deletions

View File

@ -2,18 +2,21 @@ package gap
import (
"fmt"
"strings"
"git.solsynth.dev/hypernet/nexus/pkg/nex"
"git.solsynth.dev/hypernet/nexus/pkg/proto"
"git.solsynth.dev/hypernet/pusher/pkg/pushkit/pushcon"
"github.com/rs/zerolog/log"
"github.com/samber/lo"
"strings"
"github.com/spf13/viper"
)
var Nx *nex.Conn
var Px *pushcon.Conn
var (
Nx *nex.Conn
Px *pushcon.Conn
)
func InitializeToNexus() error {
grpcBind := strings.SplitN(viper.GetString("grpc_bind"), ":", 2)
@ -30,7 +33,7 @@ func InitializeToNexus() error {
Type: nex.ServiceTypeAuth,
Label: "Passport",
GrpcAddr: grpcOutbound,
HttpAddr: lo.ToPtr("http://" + httpOutbound),
HttpAddr: lo.ToPtr("http://" + httpOutbound + "/api"),
})
if err == nil {
go func() {