Remove redundant usage of hieradata

The memcached::listen_ip_uri key in hieradata is used to define value
of the different hieradata key so is not really necessary.

Change-Id: Idddd87459ee8723dd016fc024dad2fcc37337fa3
This commit is contained in:
Takashi Kajinami 2022-05-30 15:10:38 +09:00
parent 1b0bd3cef1
commit 0b9d3bf777

View File

@ -199,16 +199,6 @@ outputs:
- is_ipv6 - is_ipv6
- 'notls:[::1]:11211' - 'notls:[::1]:11211'
- 'notls:127.0.0.1:11211' - 'notls:127.0.0.1:11211'
memcached::listen_ip_uri:
- if:
- is_ipv6
- '::1'
- '127.0.0.1'
- str_replace:
template:
"%{lookup('$NETWORK_uri')}"
params:
$NETWORK: {get_param: [ServiceNetMap, MemcachedNetwork]}
memcached::tcp_port: {get_param: MemcachedPort} memcached::tcp_port: {get_param: MemcachedPort}
memcached::max_connections: {get_param: MemcachedMaxConnections} memcached::max_connections: {get_param: MemcachedMaxConnections}
memcached::max_memory: {get_param: MemcachedMaxMemory} memcached::max_memory: {get_param: MemcachedMaxMemory}
@ -238,7 +228,16 @@ outputs:
- memcached - memcached
collectd::plugin::memcached::instances: collectd::plugin::memcached::instances:
local: local:
host: "%{lookup('memcached::listen_ip_uri')}" host:
- if:
- is_ipv6
- '::1'
- '127.0.0.1'
- str_replace:
template:
"%{lookup('$NETWORK_uri')}"
params:
$NETWORK: {get_param: [ServiceNetMap, MemcachedNetwork]}
port: # collectd has no support to Memcached+TLS yet. port: # collectd has no support to Memcached+TLS yet.
- if: - if:
- enable_non_tls_port - enable_non_tls_port