Compare commits
No commits in common. "master" and "master" have entirely different histories.
17
.drone.yml
Normal file
17
.drone.yml
Normal file
@ -0,0 +1,17 @@
|
||||
kind: pipeline
|
||||
name: validate-json
|
||||
|
||||
steps:
|
||||
- name: validate ucDevices.json
|
||||
image: fftdf/docker-json-validate
|
||||
commands:
|
||||
- jsonlint ucDevices.json
|
||||
when:
|
||||
event: push
|
||||
|
||||
- name: validate Devices.json
|
||||
image: fftdf/docker-json-validate
|
||||
commands:
|
||||
- jsonlint devices.json
|
||||
when:
|
||||
event: push
|
@ -1,30 +0,0 @@
|
||||
platform: linux/arm64
|
||||
|
||||
pipeline:
|
||||
validate_rifu:
|
||||
image: git.freifunk-rhein-sieg.net/freifunk-troisdorf/docker-json-validate
|
||||
commands:
|
||||
- jsonlint rifu_devices.json
|
||||
when:
|
||||
event: push
|
||||
|
||||
validate_router:
|
||||
image: git.freifunk-rhein-sieg.net/freifunk-troisdorf/docker-json-validate
|
||||
commands:
|
||||
- jsonlint uisp_router.json
|
||||
when:
|
||||
event: push
|
||||
|
||||
validate_unifi:
|
||||
image: git.freifunk-rhein-sieg.net/freifunk-troisdorf/docker-json-validate
|
||||
commands:
|
||||
- jsonlint unifi_devices.json
|
||||
when:
|
||||
event: push
|
||||
|
||||
validate_gateways:
|
||||
image: git.freifunk-rhein-sieg.net/freifunk-troisdorf/docker-json-validate
|
||||
commands:
|
||||
- jsonlint gateways.json
|
||||
when:
|
||||
event: push
|
86
README.md
86
README.md
@ -1,85 +1,5 @@
|
||||
## Config
|
||||
# ubnt-api-devices
|
||||
|
||||
### Unifi Access Points (unifi_devices.json)
|
||||
Geräte des Unifi Controller und UNMS die auf der Map map.freifunk-troisdorf.de angezeigt werden sollen.
|
||||
|
||||
In der Datei unifi_devices.json können die Access Points gepflegt werden, die auf der Freifunk Map erscheinen sollen.
|
||||
|
||||
Hierzu muss die Datei im json Format erweitert werden.
|
||||
|
||||
Für jedes Gerät muss dieser Block angelegt werden:
|
||||
```json
|
||||
{
|
||||
"name": "ROUTERNAME",
|
||||
"mac": "00:00:00:00:00",
|
||||
"gateway_nexthop": "1234567890",
|
||||
"gateway": "1234567890",
|
||||
"linked_to": "18:e8:29:24:17:0a",
|
||||
"domain": "unifi",
|
||||
"location": {
|
||||
"longitude":7.148406208,
|
||||
"latitude":50.817093402
|
||||
},
|
||||
```
|
||||
Erklärung:
|
||||
* name: Dient nur zur Wiedererkennung. Auf der Map erscheint der Name aus dem Unifi Controller
|
||||
* mac: Die MAC Adresse des Access Points. Zu finden im Controller. (Statistik Übersicht in der Geräteansicht)
|
||||
* gateway_nexthop: Die Node ID (MAC ohne :) des Freifunk Routers an den der AP angeschlossen ist.
|
||||
* gateway: Im Normalfall die NodeID des Supernodes (zu finden in der MAP)
|
||||
* linked_to: (Optional) Die MAC Adresse des Routers an dem der AP angeschlossen ist. Normalerweise gateway_nexthop mit Doppelpunkten. Wenn nicht gesetzt wird kein Link auf der Map angezeigt.
|
||||
* domain: Die Domain in der sich der AP befindet. (tdf, inn, flu)
|
||||
|
||||
### UISP Richtfunkstrecken
|
||||
|
||||
In der Datei rifu_devices.json können die Richtfunkstrecken gepflegt werden, die auf der Freifunk Map erscheinen sollen.
|
||||
|
||||
```json
|
||||
{
|
||||
"name": "Rathaus2Bahnhof",
|
||||
"mac": "18:E8:29:8E:C6:4D",
|
||||
"gateway_nexthop": "18e8292f7de6",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.148406208,
|
||||
"latitude":50.817093402
|
||||
}
|
||||
}
|
||||
```
|
||||
Erklärung:
|
||||
* name: Dient nur zur Wiedererkennung. Auf der Map erscheint der Name aus dem UNMS Controller
|
||||
* mac: Die MAC Adresse des Gerätes. Zu finden im Controller.
|
||||
* gateway_nexthop: Die Node ID (MAC ohne :) des Freifunk Routers an dem das Gerät angeschlossen ist.
|
||||
* gateway: Im Normalfall die NodeID des Supernodes (zu finden in der MAP)
|
||||
* domain: Die Domain in der sich der AP befindet. (tdf, inn, flu)
|
||||
|
||||
### UISP Router
|
||||
|
||||
In dieser datei werden die Router (meist ER-X) gepflegt. Diese Daten werden dann ebenfalls aus der UISP API Importiert.
|
||||
|
||||
```json
|
||||
{
|
||||
"name": "Rathaus Uplink",
|
||||
"mac": "18:e8:29:ad:9a:34",
|
||||
"gateway_nexthop": "18e8292f7de6",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "tdf",
|
||||
"location": {
|
||||
"longitude":7.149406208,
|
||||
"latitude":50.817093402
|
||||
}
|
||||
},
|
||||
```
|
||||
|
||||
### Gateways.json
|
||||
|
||||
Hier werden Statische Geräte eingetragen die auf dem Proxmox Cluster laufen.
|
||||
|
||||
```json
|
||||
{
|
||||
"name": "VPN01",
|
||||
"fqdn": "vpn01.fftdf.de",
|
||||
"mac": "00:00:00:00:00:01",
|
||||
"domain": "VPN1",
|
||||
"adresses": ["5.9.220.114"]
|
||||
},
|
||||
```
|
||||
Siehe: https://git.freifunk-rhein-sieg.net/Freifunk-Troisdorf/ubnt-freifunk-map-api
|
||||
|
26
devices.json
Normal file
26
devices.json
Normal file
@ -0,0 +1,26 @@
|
||||
{
|
||||
"devices":[
|
||||
{
|
||||
"name": "Rathaus2Bahnhof",
|
||||
"mac": "18:E8:29:8E:C6:4D",
|
||||
"gateway_nexthop": "18e8292f7de6",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.148406208,
|
||||
"latitude":50.817093402
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Bahnhof2Rathaus",
|
||||
"mac": "18:e8:29:dc:c3:7e",
|
||||
"gateway_nexthop": "18e8292f7de6",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.150436640,
|
||||
"latitude":50.814456507
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
@ -1,39 +0,0 @@
|
||||
{
|
||||
"devices":[
|
||||
{
|
||||
"name": "VPN01",
|
||||
"fqdn": "vpn01.fftdf.de",
|
||||
"mac": "00:00:00:00:00:01",
|
||||
"domain": "VPN1",
|
||||
"adresses": ["5.9.220.114"]
|
||||
},
|
||||
{
|
||||
"name": "CORE4",
|
||||
"fqdn": "core4.fftdf.de",
|
||||
"mac": "16:8f:8c:38:74:8b",
|
||||
"domain": "Backbone",
|
||||
"adresses": ["185.66.193.107"]
|
||||
},
|
||||
{
|
||||
"name": "troidsorf4",
|
||||
"fqdn": "4.fftdf.de",
|
||||
"mac": "a2:8c:ae:6f:f6:04",
|
||||
"domain": "tdf",
|
||||
"adresses": ["185.66.193.104"]
|
||||
},
|
||||
{
|
||||
"name": "troidsorf5",
|
||||
"fqdn": "5.fftdf.de",
|
||||
"mac": "a2:8c:ae:6f:f6:05",
|
||||
"domain": "inn",
|
||||
"adresses": ["185.66.193.105"]
|
||||
},
|
||||
{
|
||||
"name": "troidsorf6",
|
||||
"fqdn": "6.fftdf.de",
|
||||
"mac": "a2:8c:ae:6f:f6:06",
|
||||
"domain": "flu",
|
||||
"adresses": ["185.66.193.106"]
|
||||
}
|
||||
]
|
||||
}
|
@ -1,70 +0,0 @@
|
||||
{
|
||||
"devices":[
|
||||
{
|
||||
"name": "Rathaus2Bahnhof",
|
||||
"mac": "18:E8:29:8E:C6:4D",
|
||||
"gateway_nexthop": "18e8292f7de6",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.148406208,
|
||||
"latitude":50.817093402
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Bahnhof2Rathaus",
|
||||
"mac": "18:e8:29:dc:c3:7e",
|
||||
"gateway_nexthop": "18e8292f7de6",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.150436640,
|
||||
"latitude":50.814456507
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Rathaus2Lindenstr",
|
||||
"mac": "68:d7:9a:a8:ce:49",
|
||||
"gateway_nexthop": "a28cae6ff604",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.147861719,
|
||||
"latitude":50.817276420
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Lindenstr2Rathaus",
|
||||
"mac": "68:d7:9a:a8:30:b8",
|
||||
"gateway_nexthop": "a28cae6ff604",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.138409615,
|
||||
"latitude":50.817188300
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Haus7toHaus1",
|
||||
"mac": "24:5a:4c:f0:ac:3f",
|
||||
"gateway_nexthop": "a28cae6ff604",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.138389498,
|
||||
"latitude":50.817188300
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Haus1toHaus7",
|
||||
"mac": "24:5a:4c:f0:ad:36",
|
||||
"gateway_nexthop": "a28cae6ff604",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "rifu",
|
||||
"location": {
|
||||
"longitude":7.140045762,
|
||||
"latitude":50.816302857
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
File diff suppressed because it is too large
Load Diff
@ -1,60 +0,0 @@
|
||||
|
||||
{
|
||||
"devices":[
|
||||
{
|
||||
"name": "Rathaus Uplink",
|
||||
"mac": "18:e8:29:ad:9a:34",
|
||||
"gateway_nexthop": "18e8292f7de6",
|
||||
"gateway": "a28cae6ff604",
|
||||
"domain": "tdf",
|
||||
"location": {
|
||||
"longitude":7.149406208,
|
||||
"latitude":50.817093402
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "edge2-test",
|
||||
"mac": "d0:21:f9:bb:db:d0",
|
||||
"gateway_nexthop": "000000000001",
|
||||
"gateway": "168f8c38748b",
|
||||
"domain": "VPN1",
|
||||
"location": {
|
||||
"longitude":7.133350968,
|
||||
"latitude":50.802853080
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Aggertal-Hotel",
|
||||
"mac": "d0:21:f9:bb:e7:52",
|
||||
"gateway_nexthop": "000000000001",
|
||||
"gateway": "168f8c38748b",
|
||||
"domain": "VPN1",
|
||||
"location": {
|
||||
"longitude":7.255375,
|
||||
"latitude":50.881177
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Achtermann-edge4",
|
||||
"mac": "d0:21:f9:bb:db:8e",
|
||||
"gateway_nexthop": "000000000001",
|
||||
"gateway": "168f8c38748b",
|
||||
"domain": "VPN1",
|
||||
"location": {
|
||||
"longitude":7.122906,
|
||||
"latitude":50.819198
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "Galerie-Troisdorf",
|
||||
"mac": "d0:21:f9:bb:dc:06",
|
||||
"gateway_nexthop": "000000000001",
|
||||
"gateway": "168f8c38748b",
|
||||
"domain": "VPN1",
|
||||
"location": {
|
||||
"longitude":7.155843973,
|
||||
"latitude":50.814017575
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
Loading…
Reference in New Issue
Block a user