Skip to content

Commit 6b7c51f

Browse files
committed
be positive
1 parent e10c98b commit 6b7c51f

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

robot/web/options/options.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ type Options struct {
6868
WebRTCOnPeerAdded func(pc *webrtc.PeerConnection)
6969
WebRTCOnPeerRemoved func(pc *webrtc.PeerConnection)
7070

71-
DisableMulticastDNS bool
71+
MulticastDNS bool
7272
}
7373

7474
// New returns a default set of options which will have the

robot/web/web.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -927,7 +927,7 @@ func (svc *webService) initRPCOptions(listenerTCPAddr *net.TCPAddr, options webo
927927
OnPeerRemoved: options.WebRTCOnPeerRemoved,
928928
}),
929929
}
930-
if options.DisableMulticastDNS {
930+
if !options.MulticastDNS {
931931
rpcOpts = append(rpcOpts, rpc.WithDisableMulticastDNS())
932932
}
933933

web/server/entrypoint.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ type Arguments struct {
5454
RevealSensitiveConfigDiffs bool `flag:"reveal-sensitive-config-diffs,usage=show config diffs"`
5555
UntrustedEnv bool `flag:"untrusted-env,usage=disable processes and shell from running in a untrusted environment"`
5656
OutputTelemetry bool `flag:"output-telemetry,usage=print out telemetry data (metrics and spans)"`
57-
DisableMulticastDNS bool `flag:"disable-mdns,usage=disable server discovery through multicast DNS"`
57+
MulticastDNS bool `flag:"mdns,default=true,usage=enable server discovery through multicast DNS"`
5858
}
5959

6060
type robotServer struct {
@@ -199,7 +199,7 @@ func (s *robotServer) createWebOptions(cfg *config.Config) (weboptions.Options,
199199
options.SharedDir = s.args.SharedDir
200200
options.Debug = s.args.Debug || cfg.Debug
201201
options.WebRTC = s.args.WebRTC
202-
options.DisableMulticastDNS = s.args.DisableMulticastDNS
202+
options.MulticastDNS = s.args.MulticastDNS
203203
if cfg.Cloud != nil && s.args.AllowInsecureCreds {
204204
options.SignalingDialOpts = append(options.SignalingDialOpts, rpc.WithAllowInsecureWithCredentialsDowngrade())
205205
}

0 commit comments

Comments
 (0)