Skip to content

Commit e2c2ec9

Browse files
committed
Semantic fixes
1 parent 4dd7652 commit e2c2ec9

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

cmd/consul-dataplane/main.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,8 @@ func init() {
6767
flag.StringVar(&readyBindAddr, "envoy-ready-bind-address", "", "The address on which Envoy's readiness probe will be available.")
6868
flag.IntVar(&readyBindPort, "envoy-ready-bind-port", 0, "The port on which Envoy's readiness probe will be available.")
6969

70-
flag.StringVar(&xdsBindAddr, "xds-bind-addr", "127.0.0.1", "The address on which the envoy xDS server will be available.")
71-
flag.IntVar(&xdsBindPort, "xds-bind-port", 0, "The port on which the envoy xDS server will be available.")
70+
flag.StringVar(&xdsBindAddr, "xds-bind-addr", "127.0.0.1", "The address on which the Envoy xDS server will be available.")
71+
flag.IntVar(&xdsBindPort, "xds-bind-port", 0, "The port on which the Envoy xDS server will be available.")
7272
}
7373

7474
// validateFlags performs semantic validation of the flag values

pkg/consuldp/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ type EnvoyConfig struct {
7676
ReadyBindPort int
7777
}
7878

79-
//
79+
// XDSServer contains the configuration of the xDS server.
8080
type XDSServer struct {
8181
// BindAddress is the address on which the Envoy xDS server will be available.
8282
BindAddress string

pkg/consuldp/xds.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ func (cdp *ConsulDataplane) director(ctx context.Context, fullMethodName string)
3434
mdCopy = md.Copy()
3535
}
3636
// TODO (NET-148): Inject the ACL token acquired from the server discovery library
37-
mdCopy[metadataKeyToken] = []string{cdp.cfg.Consul.Credentials.Static.Token}
37+
mdCopy.Set(metadataKeyToken, cdp.cfg.Consul.Credentials.Static.Token)
3838
outCtx := metadata.NewOutgoingContext(ctx, mdCopy)
3939
return outCtx, cdp.consulServer.grpcClientConn, nil
4040
}

0 commit comments

Comments
 (0)