Monitoring Server + Data Collection Daemon
|
|
8 месяцев назад | |
|---|---|---|
| .vscode | 3 лет назад | |
| bootstrap-theme @ c93759376b | 3 лет назад | |
| common | 11 месяцев назад | |
| daemon | 11 месяцев назад | |
| fcm | 3 лет назад | |
| ng | 2 лет назад | |
| server | 8 месяцев назад | |
| .dockerignore | 2 лет назад | |
| .gitignore | 2 лет назад | |
| .gitmodules | 3 лет назад | |
| .prettierrc.js | 3 лет назад | |
| Readme.md | 2 лет назад | |
| server.docker-compose.dev.yml | 2 лет назад | |
| server.docker-compose.yml | 8 месяцев назад | |
| server.dockerfile | 1 год назад |
curl -fsSL https://gogs.hostbbq.com/hostbbq/hostbbq-monitoring/raw/master/daemon/install/install.sh | sudo -E bash -
ℹ Für Entwicklungszwecke kann der Monitoring Server auch lokal betrieben werden. ⚠ Dabei muss allerdings darauf geachtet werden, dass der Sync für die Server Metrics deaktiviert ist (
DEV_MODE=1), damit der lokale DEV Server nicht der Live-Instanz die Server Metrics Daten weg klaut.
Runtime Dependencies installieren:
$ cd server/
$ npm install
Live-Datenbank kopieren:
z.B. per Terminal mittels scp:
$ mkdir data
$ scp -p <user>@portantonio.hostbbq.net:/opt/hbbq/monitoring/server/data/data.db ./data/data-live.db
# data/data-live.db als Sicherung behalten, falls was schief geht,
# data/data.db aus Kopie von data/data-live.db erstellen:
$ cp data/data-live.db data/data.db
... oder auch einfach manuell mit WinSCP/FileZilla/... (ℹ Das Datenbank-File muss nach server/data/data.db - falls Unterordner noch nicht vorhanden, anlegen.)
.env-File (in server/-Root) mit folgendem Inhalt anlegen:
LOG_LEVEL=DEBUG
WEB_PORT=8880
DATA_DIR=data
GOOGLE_APPLICATION_CREDENTIALS="google-cloud/firebase-adminsdk.json"
NOTIFICATION_ICON_URL="https://fcm.hostbbq.net/logo.png"
DEV_MODE=1
Server starten:
$ npm start
Danach sollte der Server unter [http://localhost:8880]() zur Verfügung stehen.
ng/proxy-conf.json:
@@ -1,7 +1,7 @@
[
{
"context": ["/api"],
- "target": "http://10.8.0.1:8880",
+ "target": "http://localhost:8880",
"secure": false,
"pathRewrite": { "^/api": "" }
}
Angular Dev Server wie gewohnt starten:
$ cd ng/
$ (npm install)?
$ npm start
curl -fsSL https://gogs.hostbbq.com/hostbbq/hostbbq-monitoring/raw/master/server/install/install.sh | sudo -E bash -
curl -fsSL https://gogs.hostbbq.com/hostbbq/hostbbq-monitoring/raw/master/fcm/install/install.sh | sudo -E bash -