Add options to set ports on weaver command line
This commit adds two command line options, intended to allow multiple instances of weave to run without container separation between them. * -port=PORT makes weave bind to port PORT (an integer). Without the option, the default value (6783) is used. * -httpaddr=ADDRESS makes weave bind its control interface to a different address. For instance "127.0.0.1:6784" can be used to bind to localhost only. An absent address element makes it bind to all interfaces. ":6784" is the default. An empty string can be used to disable the control interface. Signed-off-by: Alex Bligh <alex@alex.org.uk>
This commit is contained in:
1 parent
bb9e26b4ae
commit
12d88eac23
7 files changed
+49
-40
No files matched your search
@@ -48,7 +48,7 @@ func NewRawUDPSender(conn *LocalConnection) (*RawUDPSender, error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
udpHeader := &layers.UDP{SrcPort: layers.UDPPort(Port)}
|
||||
udpHeader := &layers.UDP{SrcPort: layers.UDPPort(conn.Router.Port)}
|
||||
ipBuf := gopacket.NewSerializeBuffer()
|
||||
opts := gopacket.SerializeOptions{
|
||||
FixLengths: true,
|
||||
|
||||
Reference in new issue
Block a user