Allow hostnames to be used as ip_address

Previously introduced change for monasca-persister
had enforced the IPAddress as the only type one can
configure influxdb.ip_address property with.

Following change makes it possible to use also hostname.
Using IPAdress is still possible.

Change-Id: Ib0d7f19b3ac2dcb7c84923872d94f180cda58b2b
This commit is contained in:
Tomasz Trębski 2017-10-19 06:47:23 +02:00
parent 8dba608c42
commit 66fe6f98c0
1 changed files with 3 additions and 2 deletions

View File

@ -20,8 +20,9 @@ influxdb_opts = [
cfg.StrOpt('database_name',
help='database name where metrics are stored',
default='mon'),
cfg.IPOpt('ip_address',
help='ip address to influxdb'),
cfg.HostAddressOpt('ip_address',
help='Valid IP address or hostname '
'to InfluxDB instance'),
cfg.PortOpt('port',
help='port to influxdb',
default=8086),