Skip to content
Merged

Fixes #3317

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion data/config/apt/99openwb
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
# openwb-version:1
# openwb-version:2
# may speedup booting
Acquire::http::Timeout "10";
Acquire::ftp::Timeout "10";
# keep system light and clean
APT::Get::Install-Recommends "false";
APT::Get::Install-Suggests "false";
Dpkg::Options {
"--force-confold";
"--force-confdef";
};
7 changes: 4 additions & 3 deletions packages/helpermodules/subdata.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,8 @@ def process_vehicle_topic(self, client: mqtt.Client, var: Dict[str, ev.Ev], msg:
if decode_payload(msg.payload) == "":
if re.search("/vehicle/[0-9]+/soc_module/config$", msg.topic) is not None:
var["ev"+index].soc_module = None
remove_acl_role("vehicle-<id>-write-access", int(index))
if self.system_data["system"].data["security"]["user_management_active"]:
remove_acl_role("vehicle-<id>-write-access", int(index))
elif re.search("/vehicle/[0-9]+/get", msg.topic) is not None:
self.set_json_payload_class(var["ev"+index].data.get, msg)
else:
Expand Down Expand Up @@ -502,10 +503,10 @@ def process_chargepoint_config_topic(self, var: Dict[str, chargepoint.CpTemplate
self.event_start_internal_chargepoint.set()
if (payload["type"] == "external_openwb"):
new_ip = payload["configuration"].get("ip_address", None)
if old_ip != new_ip:
if self.system_data["system"].data["security"]["user_management_active"] and old_ip != new_ip:
log.debug(f"IP of chargepoint {index} changed, modifying display user")
if old_ip is not None:
# check if ip is used in other chargepoints, if not remove display user
# check if ip is used in other charge points, if not remove display user
for cp in var:
if (
var[cp].chargepoint.data.config.configuration.get("ip_address", None) == old_ip
Expand Down
Loading