From 11ce4753eaf481a8d9a98326f81d9e1c1a4edc9b Mon Sep 17 00:00:00 2001 From: Hongbin Lu Date: Mon, 2 Jan 2017 12:32:48 -0600 Subject: [PATCH] Rename config host to host_ip in api group The 'host' config is actually an IP address. Let's rename it to make it clear and consistent with other projects (i.e. Ironic). Change-Id: I48a8a69c5049341afff545fcabebf0053ab1d242 --- devstack/lib/zun | 2 +- zun/common/service.py | 2 +- zun/conf/api.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/devstack/lib/zun b/devstack/lib/zun index 96e2df92f..5e53a38e4 100644 --- a/devstack/lib/zun +++ b/devstack/lib/zun @@ -198,7 +198,7 @@ function create_zun_conf { iniset $ZUN_CONF database connection `database_connection_url zun` iniset $ZUN_CONF etcd etcd_host "$HOST_IP" iniset $ZUN_CONF etcd etcd_port 2379 - iniset $ZUN_CONF api host "$ZUN_SERVICE_HOST" + iniset $ZUN_CONF api host_ip "$ZUN_SERVICE_HOST" iniset $ZUN_CONF api port "$ZUN_SERVICE_PORT" iniset $ZUN_CONF oslo_policy policy_file $ZUN_POLICY_JSON diff --git a/zun/common/service.py b/zun/common/service.py index 2ff5aa82d..fb158025f 100644 --- a/zun/common/service.py +++ b/zun/common/service.py @@ -64,7 +64,7 @@ class WSGIService(service.ServiceBase): "must be greater than 0.") % self.workers) self.server = wsgi.Server(CONF, name, self.app, - host=CONF.api.host, + host=CONF.api.host_ip, port=CONF.api.port, use_ssl=use_ssl) diff --git a/zun/conf/api.py b/zun/conf/api.py index 0a8a13763..3fcf83758 100644 --- a/zun/conf/api.py +++ b/zun/conf/api.py @@ -18,7 +18,7 @@ api_service_opts = [ cfg.PortOpt('port', default=9512, help='The port for the zun API server.'), - cfg.IPOpt('host', + cfg.IPOpt('host_ip', default='127.0.0.1', help='The listen IP for the zun API server.'), cfg.BoolOpt('enable_ssl_api',