Skip to content

Commit 58d22a3

Browse files
authored
Merge pull request #92 from play-iot/release/vpnc/0.9.5
Release/vpnc/0.9.5
2 parents cfacea6 + 39b1f57 commit 58d22a3

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

cli/CHANGELOG-VPNC.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# Changelog
22

3+
## [v0.9.5](https://github.com/play-iot/iot-vpn/tree/vpnc/v0.9.5) (2021-06-14)
4+
5+
### Changes
6+
7+
- Resolve [#85](https://github.com/play-iot/iot-vpn/issues/85)
8+
- Resolve [#86](https://github.com/play-iot/iot-vpn/issues/86)
9+
- Resolve [#66](https://github.com/play-iot/iot-vpn/issues/66)
10+
311
## [v0.9.4](https://github.com/play-iot/iot-vpn/tree/vpnc/v0.9.4) (2021-06-10)
412

513
### Changes

cli/python/src/client/cmd_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ def lease_vpn_ip(self, account: str, log_lvl=logger.DEBUG):
383383
loop_interval(lambda: self.get_vpn_status(account)['connected'],
384384
'Unable connect VPN. Please check log for more detail', max_retries=3, interval=1)
385385
nic = self.opts.account_to_nic(account)
386-
if not self.device.dns_resolver.is_enable_connman_dhcp():
386+
if self.device.dns_resolver.is_connman() and not self.device.dns_resolver.is_enable_connman_dhcp():
387387
logger.log(logger.WARN, f'Please lease VPN IP manually by ' +
388388
f'[{self.device.ip_resolver.lease_ip(account, nic, daemon=True, is_execute=False)}]')
389389
return

cli/python/src/client/device_resolver.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -547,7 +547,9 @@ def is_connman(self) -> bool:
547547
return self.kind is DNSResolverType.CONNMAN
548548

549549
def is_enable_connman_dhcp(self) -> bool:
550-
return self.is_connman() and FileHelper.read_file_by_line(self.connman_dhcp, '0').lower() in ('true', 't', '1')
550+
yes_ = ('true', 't', 'yes', '1')
551+
return self.is_connman() and FileHelper.read_file_by_line(self.connman_dhcp,
552+
fallback_if_not_exists='0').lower() in yes_
551553

552554
def is_dnsmasq_available(self):
553555
return self.kind.is_dnsmasq() or self._is_dnsmasq

0 commit comments

Comments
 (0)