c12s-kubespray/roles/kubernetes-apps/ansible/templates/glusterfs-kubernetes-endpoint.json.j2

25 lines
383 B
Text
Raw Normal View History

{
"kind": "Endpoints",
"apiVersion": "v1",
"metadata": {
2016-11-16 15:21:46 +00:00
"name": "glusterfs"
},
"subsets": [
2016-11-16 15:21:46 +00:00
{% for host in groups['gfs-cluster'] %}
{
"addresses": [
2016-11-16 15:21:46 +00:00
{
"ip": "{{hostvars[host]['ip']}}"
}
],
"ports": [
{
"port": 1
}
]
2016-11-16 15:21:46 +00:00
}{%- if not loop.last %}, {% endif -%}
{% endfor %}
]
}