summaryrefslogtreecommitdiff
path: root/scripts/templates/eip-service.json
blob: 8d1b0a1b4b877ed6dae6a0e410a33b6190e9f78a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{
    "serial": 3,
    "version": 3,
    "locations": { {% for loc in locations %}
        "{{loc}}": {
            "name": "{{ locations[loc]["name"] }}",
            "country_code": "{{ locations[loc]["country_code"] }}",
            "hemisphere": "{{ locations[loc]["hemisphere"] }}",
            "timezone": {{ locations[loc]["timezone"] }},
        },{% endfor %}
    },
    "gateways": { {% for gw in gateways %}
        "{{gw}}": {
            "host": "{{ gateways[gw]["host"] }}",
            "ip_address": "{{ gateways[gw]["ip_address"] }}",
            "location": "{{ gateways[gw]["location"] }}",
            "capabilities": {
                "adblock": false,
                "filter_dns": false,
                "limited": false,
                "transport": [ {% for tr, proto, port, options in gateways[gw]["transports"] %}
                    {"type": "{{ tr }}",
                     "protocols": ["{{ proto }}"],
                     "ports": [{{ port }}],{% if options %}
                     "options": {{ options | tojson }},{% endif %}
                    },{% endfor %}
                ],
            },
        },{% endfor %}
    },
    "openvpn_configuration": {{ openvpn|tojson(indent=8) }}
}