controller: Change default OPF listen host to "0.0.0.0"
With netaddr.valid_ipv4/6, empty host is not allowed and will fail to validate. This patch changes to the default openflow listen host to "0.0.0.0" and enable to validate it by using netaddr. Note: The default behavior is NOT changed. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
parent
9efde1d2f5
commit
793dc13e01
@ -48,9 +48,12 @@ from ryu.lib.dpid import dpid_to_str
|
|||||||
|
|
||||||
LOG = logging.getLogger('ryu.controller.controller')
|
LOG = logging.getLogger('ryu.controller.controller')
|
||||||
|
|
||||||
|
DEFAULT_OFP_HOST = '0.0.0.0'
|
||||||
|
|
||||||
CONF = cfg.CONF
|
CONF = cfg.CONF
|
||||||
CONF.register_cli_opts([
|
CONF.register_cli_opts([
|
||||||
cfg.StrOpt('ofp-listen-host', default='', help='openflow listen host'),
|
cfg.StrOpt('ofp-listen-host', default=DEFAULT_OFP_HOST,
|
||||||
|
help='openflow listen host (default %s)' % DEFAULT_OFP_HOST),
|
||||||
cfg.IntOpt('ofp-tcp-listen-port', default=None,
|
cfg.IntOpt('ofp-tcp-listen-port', default=None,
|
||||||
help='openflow tcp listen port '
|
help='openflow tcp listen port '
|
||||||
'(default: %d)' % ofproto_common.OFP_TCP_PORT),
|
'(default: %d)' % ofproto_common.OFP_TCP_PORT),
|
||||||
|
Loading…
Reference in New Issue
Block a user