Fix yum proxy logic in repo template
Previously if the proxy host was defined but empty, an invalid proxy was config was added and the install would fail. This is likely to occur for instances where you conditionally set the proxy.
This commit is contained in:
parent
9197f2fbcd
commit
7876a662ca
1 changed files with 1 additions and 2 deletions
|
|
@ -4,7 +4,6 @@ baseurl=https://artifacts.elastic.co/packages/{{ es_major_version }}/yum
|
||||||
gpgcheck=1
|
gpgcheck=1
|
||||||
gpgkey=https://artifacts.elastic.co/GPG-KEY-elasticsearch
|
gpgkey=https://artifacts.elastic.co/GPG-KEY-elasticsearch
|
||||||
enabled=1
|
enabled=1
|
||||||
{% if es_proxy_host is defined and es_proxy_port is defined %}
|
{% if es_proxy_host is defined and es_proxy_host != '' and es_proxy_port is defined %}
|
||||||
proxy=http://{{ es_proxy_host }}:{{es_proxy_port}}
|
proxy=http://{{ es_proxy_host }}:{{es_proxy_port}}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue