From c98c7e698698deb24df68a0ea2a61034a5161386 Mon Sep 17 00:00:00 2001 From: "jeremy.zhang" Date: Tue, 28 Mar 2017 11:34:56 +0800 Subject: [PATCH] Use HostAddressOpt for opts that accept IP and hostnames Some configuration options were accepting both IP addresses and hostnames. Since there was no specific OSLO opt type to support this, we were using ``StrOpt``. The change [1] that added support for ``HostAddressOpt`` type was merged in Ocata and became available for use with oslo version 3.22. This patch changes the opt type of configuration options to use this more relevant opt type - HostAddressOpt. [1] I77bdb64b7e6e56ce761d76696bc4448a9bd325eb Change-Id: I66fb2097a4b6908fc6ee9f41ff141d3067a18a31 --- fuxi/common/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fuxi/common/config.py b/fuxi/common/config.py index ad1fa26..2dc0960 100644 --- a/fuxi/common/config.py +++ b/fuxi/common/config.py @@ -21,8 +21,8 @@ from fuxi.i18n import _ from fuxi.version import version_info default_opts = [ - cfg.StrOpt('my_ip', - help=_('IP address of this machine.')), + cfg.HostAddressOpt('my_ip', + help=_('IP address of this machine.')), cfg.IntOpt('fuxi_port', default=7879, help=_('Port for fuxi volume driver server.')),