mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-10 07:44:50 +01:00
obuspa: 6.0.0.12
This commit is contained in:
parent
08a31cccad
commit
4b05713ae7
3 changed files with 10 additions and 42 deletions
|
|
@ -5,7 +5,7 @@
|
||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=obuspa
|
PKG_NAME:=obuspa
|
||||||
PKG_VERSION:=6.0.0.11
|
PKG_VERSION:=6.0.0.12
|
||||||
|
|
||||||
LOCAL_DEV:=0
|
LOCAL_DEV:=0
|
||||||
ifneq ($(LOCAL_DEV),1)
|
ifneq ($(LOCAL_DEV),1)
|
||||||
|
|
|
||||||
|
|
@ -11,54 +11,22 @@ config obuspa 'global'
|
||||||
#option log_dest '/var/log/obuspa'
|
#option log_dest '/var/log/obuspa'
|
||||||
|
|
||||||
# Adds Device.LocalAgent.MTP.
|
# Adds Device.LocalAgent.MTP.
|
||||||
config mtp 'agent_mtp'
|
config mtp 'test_mtp'
|
||||||
option Protocol 'MQTT'
|
option Protocol 'MQTT'
|
||||||
option ResponseTopicConfigured '/usp/endpoint'
|
option ResponseTopicConfigured '/usp/endpoint'
|
||||||
option mqtt 'localmqtt'
|
option mqtt 'testmqtt'
|
||||||
|
|
||||||
# Adds Device.MQTT.Client.
|
# Adds Device.MQTT.Client.
|
||||||
config mqtt 'localmqtt'
|
config mqtt 'testmqtt'
|
||||||
option BrokerAddress '127.0.0.1'
|
option BrokerAddress '127.0.0.1'
|
||||||
option BrokerPort '1883'
|
option BrokerPort '1883'
|
||||||
option TransportProtocol 'TCP/IP'
|
option TransportProtocol 'TCP/IP'
|
||||||
|
|
||||||
# Adds Device.LocalAgent.Controller.
|
# Adds Device.LocalAgent.Controller.
|
||||||
config controller 'localcontroller'
|
config controller 'testcontroller'
|
||||||
option EndpointID 'proto::interop-usp-controller'
|
option EndpointID 'proto::interop-usp-controller'
|
||||||
option Protocol 'MQTT'
|
option Protocol 'MQTT'
|
||||||
option Topic '/usp/controller'
|
option Topic '/usp/controller'
|
||||||
option mqtt 'localmqtt'
|
option mqtt 'testmqtt'
|
||||||
option assigned_role_name 'full_access'
|
option assigned_role_name 'full_access'
|
||||||
|
|
||||||
# Add Device.LocalAgent.Subscription.
|
|
||||||
#config subscription 'sub_event'
|
|
||||||
# option ID 'uci-sub-events'
|
|
||||||
# option NotifType 'Event'
|
|
||||||
# list ReferenceList 'Device.Boot!'
|
|
||||||
# list ReferenceList 'Device.LocalAgent.TransferComplete!'
|
|
||||||
# option Persistent 'true'
|
|
||||||
# option controller 'localcontroller'
|
|
||||||
|
|
||||||
#config subscription 'sub_op_comp'
|
|
||||||
# option ID 'uci-sub-op_complete'
|
|
||||||
# option NotifType 'OperationComplete'
|
|
||||||
# list ReferenceList 'Device.DeviceInfo.FirmwareImage.*.Download()'
|
|
||||||
# list ReferenceList 'Device.DeviceInfo.FirmwareImage.*.Activate()'
|
|
||||||
# option Persistent 'true'
|
|
||||||
# option controller 'localcontroller'
|
|
||||||
|
|
||||||
#config challenge 'admin'
|
|
||||||
# option Description 'Request to get Administrative access'
|
|
||||||
# option role_name 'full_access'
|
|
||||||
# option Enable '1'
|
|
||||||
# option Value 'YWRtaW4='
|
|
||||||
# option Retries 2
|
|
||||||
# option LockoutPeriod 60
|
|
||||||
|
|
||||||
#config challenge 'user'
|
|
||||||
# option Description 'Request to get User access'
|
|
||||||
# option role_name 'user'
|
|
||||||
# option Enable '1'
|
|
||||||
# option Value 'dXNlcg=='
|
|
||||||
# option Retries 3
|
|
||||||
# option LockoutPeriod 30
|
|
||||||
|
|
|
||||||
|
|
@ -314,7 +314,7 @@ publish_endpoint()
|
||||||
{
|
{
|
||||||
local AgentEndpointID serial oui user pass
|
local AgentEndpointID serial oui user pass
|
||||||
|
|
||||||
if ! uci -q get obuspa.localmqtt; then
|
if ! uci -q get obuspa.testmqtt; then
|
||||||
return 0;
|
return 0;
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
@ -330,11 +330,11 @@ publish_endpoint()
|
||||||
if [ -z "${AgentEndpointID}" ]; then
|
if [ -z "${AgentEndpointID}" ]; then
|
||||||
serial=$(get_serial_from_db)
|
serial=$(get_serial_from_db)
|
||||||
oui=$(get_oui_from_db)
|
oui=$(get_oui_from_db)
|
||||||
AgentEndpointID="os::${oui}-${serial}"
|
AgentEndpointID="os::${oui}-${serial//+/%2B}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
config_get user localmqtt Username
|
config_get user testmqtt Username
|
||||||
config_get pass localmqtt Password
|
config_get pass testmqtt Password
|
||||||
|
|
||||||
# publish Agent's EndpointID in mosquito broker for discovery by usp-js
|
# publish Agent's EndpointID in mosquito broker for discovery by usp-js
|
||||||
# This is a work around till obuspa adds supports for mDNS discovery
|
# This is a work around till obuspa adds supports for mDNS discovery
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue