mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-10 07:44:50 +01:00
obuspa: 6.0.0.10
This commit is contained in:
parent
ec6533707f
commit
1ba2d5ab89
2 changed files with 16 additions and 5 deletions
|
|
@ -5,7 +5,7 @@
|
||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=obuspa
|
PKG_NAME:=obuspa
|
||||||
PKG_VERSION:=6.0.0.9
|
PKG_VERSION:=6.0.0.10
|
||||||
|
|
||||||
LOCAL_DEV:=0
|
LOCAL_DEV:=0
|
||||||
ifneq ($(LOCAL_DEV),1)
|
ifneq ($(LOCAL_DEV),1)
|
||||||
|
|
|
||||||
|
|
@ -81,6 +81,14 @@ db_set()
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
update_db_dump()
|
||||||
|
{
|
||||||
|
if [ -f "${DB_DUMP}" ]; then
|
||||||
|
rm ${DB_DUMP}
|
||||||
|
${PROG} -f ${SQL_DB_FILE} -c show database |sort > ${DB_DUMP}
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
# if db present then check if it matches with existing instances
|
# if db present then check if it matches with existing instances
|
||||||
# fallback to max instance present + 1
|
# fallback to max instance present + 1
|
||||||
# In case of no db get the count
|
# In case of no db get the count
|
||||||
|
|
@ -352,6 +360,7 @@ configure_localagent()
|
||||||
}
|
}
|
||||||
|
|
||||||
db_set Device.LocalAgent.EndpointID "${EndpointID}"
|
db_set Device.LocalAgent.EndpointID "${EndpointID}"
|
||||||
|
update_db_dump
|
||||||
}
|
}
|
||||||
|
|
||||||
update_reset_reason()
|
update_reset_reason()
|
||||||
|
|
@ -447,6 +456,7 @@ configure_controller()
|
||||||
done
|
done
|
||||||
|
|
||||||
db_set
|
db_set
|
||||||
|
update_db_dump
|
||||||
}
|
}
|
||||||
|
|
||||||
configure_subscription()
|
configure_subscription()
|
||||||
|
|
@ -580,7 +590,6 @@ configure_mtp() {
|
||||||
log "Validation of mtp section failed"
|
log "Validation of mtp section failed"
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
sec="${sec/mtp_/cpe-}"
|
sec="${sec/mtp_/cpe-}"
|
||||||
get_base_path "Device.LocalAgent.MTP." "${sec}"
|
get_base_path "Device.LocalAgent.MTP." "${sec}"
|
||||||
if [ -z "${BASEPATH}" ]; then
|
if [ -z "${BASEPATH}" ]; then
|
||||||
|
|
@ -624,6 +633,7 @@ configure_mtp() {
|
||||||
db_set "${BASEPATH}.WebSocket.EnableEncryption" "${EnableEncryption}"
|
db_set "${BASEPATH}.WebSocket.EnableEncryption" "${EnableEncryption}"
|
||||||
fi
|
fi
|
||||||
db_set
|
db_set
|
||||||
|
update_db_dump
|
||||||
}
|
}
|
||||||
|
|
||||||
configure_stomp_connection() {
|
configure_stomp_connection() {
|
||||||
|
|
@ -655,9 +665,10 @@ configure_stomp_connection() {
|
||||||
db_set "${BASEPATH}.EnableHeartbeats" "${EnableHeartbeats}"
|
db_set "${BASEPATH}.EnableHeartbeats" "${EnableHeartbeats}"
|
||||||
db_set "${BASEPATH}.VirtualHost" "${VirtualHost}"
|
db_set "${BASEPATH}.VirtualHost" "${VirtualHost}"
|
||||||
db_set
|
db_set
|
||||||
|
update_db_dump
|
||||||
}
|
}
|
||||||
|
|
||||||
configure_mqtt_client(){
|
configure_mqtt_client() {
|
||||||
local BrokerAddress BrokerPort Enable Username Password ProtocolVersion
|
local BrokerAddress BrokerPort Enable Username Password ProtocolVersion
|
||||||
local TransportProtocol ClientID
|
local TransportProtocol ClientID
|
||||||
local sec
|
local sec
|
||||||
|
|
@ -686,6 +697,7 @@ configure_mqtt_client(){
|
||||||
db_set "${BASEPATH}.ClientID" "${ClientID}"
|
db_set "${BASEPATH}.ClientID" "${ClientID}"
|
||||||
|
|
||||||
db_set
|
db_set
|
||||||
|
update_db_dump
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -955,7 +967,6 @@ delete_sql_db_entry_with_pattern()
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "${#pattern}" -lt 7 ]; then
|
if [ "${#pattern}" -lt 7 ]; then
|
||||||
log "Invalid pattern ${1}"
|
|
||||||
return 0;
|
return 0;
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
@ -970,7 +981,7 @@ check_n_delete_db()
|
||||||
local sec t r path
|
local sec t r path
|
||||||
|
|
||||||
sec="${1}"
|
sec="${1}"
|
||||||
if uci -q get obuspa.${sec}; then
|
if uci -q get obuspa.${sec} >/dev/null 2>&1; then
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue