mirror of
https://github.com/kerberos-io/agent.git
synced 2026-09-05 17:18:34 +00:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b0d2409524 | ||
|
|
be7a231950 |
@@ -1,22 +1,19 @@
|
||||
|
||||
{
|
||||
"type": "",
|
||||
"key": "a-custom-key2",
|
||||
"name": "yolo23",
|
||||
"friendly_name": "",
|
||||
"key": "",
|
||||
"name": "agent",
|
||||
"time": "false",
|
||||
"offline": "false",
|
||||
"auto_clean": "100",
|
||||
"auto_clean": "true",
|
||||
"max_directory_size": 100,
|
||||
"timezone": "Europe/Brussels",
|
||||
"timezone": "Africa/Ceuta",
|
||||
"capture": {
|
||||
"name": "",
|
||||
"ipcamera": {
|
||||
"rtsp": "rtsp://kellyvd:cedricve123@192.168.1.64:554/Streaming/Channels/101?transportmode=multicast\u0026profile=Profile_2",
|
||||
"sub_rtsp": "rtsp://kellyvd:cedricve123@192.168.1.64:554/Streaming/Channels/102?transportmode=multicast\u0026profile=Profile_2",
|
||||
"fps": "",
|
||||
"onvif_xaddr": "192.168.1.64",
|
||||
"onvif_username": "kellyvd",
|
||||
"onvif_password": "cedricve123"
|
||||
"rtsp": "",
|
||||
"sub_rtsp": "",
|
||||
"fps": ""
|
||||
},
|
||||
"usbcamera": {
|
||||
"device": ""
|
||||
@@ -24,16 +21,15 @@
|
||||
"raspicamera": {
|
||||
"device": ""
|
||||
},
|
||||
"recording": "true",
|
||||
"continuous": "false",
|
||||
"postrecording": 10,
|
||||
"prerecording": 20,
|
||||
"maxlengthrecording": 120,
|
||||
"postrecording": 20,
|
||||
"prerecording": 10,
|
||||
"maxlengthrecording": 30,
|
||||
"transcodingwebrtc": "",
|
||||
"transcodingresolution": 0,
|
||||
"forwardwebrtc": "",
|
||||
"fragmented": "true",
|
||||
"fragmentedduration": 10,
|
||||
"fragmented": "false",
|
||||
"fragmentedduration": 8,
|
||||
"pixelChangeThreshold": 150
|
||||
},
|
||||
"timetable": [
|
||||
@@ -88,43 +84,15 @@
|
||||
"x2": 800,
|
||||
"y2": 640
|
||||
},
|
||||
"polygon": [
|
||||
{
|
||||
"id": "1676324389112",
|
||||
"coordinates": [
|
||||
{
|
||||
"x": 101.30172413793105,
|
||||
"y": 147.75
|
||||
},
|
||||
{
|
||||
"x": 450.1099137931035,
|
||||
"y": 147.75
|
||||
},
|
||||
{
|
||||
"x": 450.1099137931035,
|
||||
"y": 398.5603448275862
|
||||
},
|
||||
{
|
||||
"x": 101.30172413793105,
|
||||
"y": 398.5603448275862
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
"polygon": []
|
||||
},
|
||||
"cloud": "kstorage",
|
||||
"cloud": "s3",
|
||||
"s3": {
|
||||
"proxyuri": "http://proxy.kerberos.io",
|
||||
"bucket": "kerberosaccept",
|
||||
"region": "eu-west1",
|
||||
"username": "cedricve"
|
||||
},
|
||||
"kstorage": {
|
||||
"uri": "https://api.vault.kerberos.io",
|
||||
"access_key": "AQER!@$214m2154125!TFsdgdsddb325@#%",
|
||||
"secret_access_key": ")@#%323kTEWTG@#%@)R@TWWEG",
|
||||
"directory": "cedricve"
|
||||
"region": "eu-west1"
|
||||
},
|
||||
"kstorage": {},
|
||||
"mqtturi": "tcp://mqtt.kerberos.io:1883",
|
||||
"mqtt_username": "",
|
||||
"mqtt_password": "",
|
||||
@@ -133,9 +101,9 @@
|
||||
"turn_username": "username1",
|
||||
"turn_password": "password1",
|
||||
"heartbeaturi": "",
|
||||
"hub_uri": "http://api.cloud.kerberos.io",
|
||||
"hub_key": "AKIA5V6EGLUW6KCGC2YL",
|
||||
"hub_private_key": "+mHvJ/na+4uTUmoTqr+7oG82cpizl7Dq+245UNB6",
|
||||
"hub_uri": "https://api.cloud.kerberos.io",
|
||||
"hub_key": "",
|
||||
"hub_private_key": "",
|
||||
"hub_site": "",
|
||||
"condition_uri": ""
|
||||
}
|
||||
@@ -240,6 +240,13 @@ func RunAgent(configuration *models.Configuration, communication *models.Communi
|
||||
// the agent will cleanup and restart.
|
||||
status = <-communication.HandleBootstrap
|
||||
|
||||
close(communication.HandleONVIF)
|
||||
communication.HandleONVIF = nil
|
||||
close(communication.HandleLiveHDHandshake)
|
||||
communication.HandleLiveHDHandshake = nil
|
||||
close(communication.HandleMotion)
|
||||
communication.HandleMotion = nil
|
||||
|
||||
// Here we are cleaning up everything!
|
||||
if configuration.Config.Offline != "true" {
|
||||
communication.HandleHeartBeat <- "stop"
|
||||
@@ -263,12 +270,6 @@ func RunAgent(configuration *models.Configuration, communication *models.Communi
|
||||
subQueue = nil
|
||||
communication.SubQueue = nil
|
||||
}
|
||||
close(communication.HandleONVIF)
|
||||
communication.HandleONVIF = nil
|
||||
close(communication.HandleLiveHDHandshake)
|
||||
communication.HandleLiveHDHandshake = nil
|
||||
close(communication.HandleMotion)
|
||||
communication.HandleMotion = nil
|
||||
|
||||
// Disconnect MQTT
|
||||
routers.DisconnectMQTT(mqttClient, &configuration.Config)
|
||||
|
||||
Reference in New Issue
Block a user