mirror of
https://github.com/hexolan/panels.git
synced 2026-03-26 20:41:15 +00:00
init gateway-service
This commit is contained in:
19
services/gateway-service/cmd/gateway-service/main.go
Normal file
19
services/gateway-service/cmd/gateway-service/main.go
Normal file
@@ -0,0 +1,19 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"github.com/hexolan/panels/gateway-service/internal"
|
||||
"github.com/hexolan/panels/gateway-service/internal/api"
|
||||
"github.com/hexolan/panels/gateway-service/internal/rpc"
|
||||
)
|
||||
|
||||
func main() {
|
||||
// Load the configuration
|
||||
cfg := internal.NewConfig()
|
||||
|
||||
// Connect to the RPC services
|
||||
rpc.DialRPCServices(cfg)
|
||||
|
||||
// Serve the api.
|
||||
app := api.NewAPIApp(cfg)
|
||||
api.ServeAPIApp(app)
|
||||
}
|
||||
8
services/gateway-service/cmd/gateway-service/tools.go
Normal file
8
services/gateway-service/cmd/gateway-service/tools.go
Normal file
@@ -0,0 +1,8 @@
|
||||
//go:build tools
|
||||
package main
|
||||
|
||||
import (
|
||||
// Protobuf Generation
|
||||
_ "google.golang.org/protobuf/cmd/protoc-gen-go"
|
||||
_ "google.golang.org/grpc/cmd/protoc-gen-go-grpc"
|
||||
)
|
||||
Reference in New Issue
Block a user