add grpc dial opts for grpc-gateway
All checks were successful
Build and Publish / release (push) Has been skipped
Build and Publish / check-chart (push) Successful in 11s
Build and Publish / helm-release (push) Has been skipped

This commit is contained in:
Ryan McGuire 2025-03-25 10:41:49 -04:00
parent 9077ae354a
commit 1e481627e3

5
app.go
View File

@ -6,6 +6,8 @@ import (
"gitea.libretechconsulting.com/rmcguire/go-app/pkg/app"
grpcopts "gitea.libretechconsulting.com/rmcguire/go-app/pkg/srv/grpc/opts"
httpopts "gitea.libretechconsulting.com/rmcguire/go-app/pkg/srv/http/opts"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials/insecure"
weatherpb "gitea.libretechconsulting.com/rmcguire/ambient-local-exporter/api/v1alpha1/weather"
"gitea.libretechconsulting.com/rmcguire/ambient-local-exporter/pkg/ambient"
@ -47,6 +49,9 @@ func prepareApp(ctx context.Context, aw *ambient.AmbientWeather) *app.App {
// GRPC Service for retrieving weather
GRPC: &grpcopts.AppGRPC{
GRPCDialOpts: []grpc.DialOption{
grpc.WithTransportCredentials(insecure.NewCredentials()),
},
Services: []*grpcopts.GRPCService{
{
Name: "Weather Service",