mirror of
https://gitlab.dit.htwk-leipzig.de/htwk-software/htwkalender.git
synced 2025-08-07 04:09:15 +02:00
feat:#36 added protobuf communication for modules
This commit is contained in:
@@ -21,6 +21,7 @@ import (
|
||||
"github.com/pocketbase/pocketbase/plugins/migratecmd"
|
||||
_ "htwkalender/data-manager/migrations"
|
||||
"htwkalender/data-manager/service"
|
||||
"htwkalender/data-manager/service/grpc"
|
||||
"log/slog"
|
||||
"os"
|
||||
"strings"
|
||||
@@ -32,6 +33,9 @@ func main() {
|
||||
// loosely check if it was executed using "go run"
|
||||
isGoRun := strings.HasPrefix(os.Args[0], os.TempDir())
|
||||
|
||||
//start grpc server
|
||||
go grpc.StartGRPCServer(app)
|
||||
|
||||
migratecmd.MustRegister(app, app.RootCmd, migratecmd.Config{
|
||||
// enable auto creation of migration files when making collection changes in the Admin UI
|
||||
// (the isGoRun check is to enable it only during development)
|
||||
@@ -43,4 +47,5 @@ func main() {
|
||||
if err := app.Start(); err != nil {
|
||||
slog.Error("Failed to start app: ", "error", err)
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user