diff options
Diffstat (limited to 'src')
-rwxr-xr-x | src/conf_mode/container.py | 4 | ||||
-rwxr-xr-x | src/op_mode/dhcp.py | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/src/conf_mode/container.py b/src/conf_mode/container.py index ded370a7a..14387cbbf 100755 --- a/src/conf_mode/container.py +++ b/src/conf_mode/container.py @@ -421,6 +421,10 @@ def generate(container): 'driver': 'host-local' } } + + if 'no_name_server' in network_config: + tmp['dns_enabled'] = False + for prefix in network_config['prefix']: net = {'subnet': prefix, 'gateway': inc_ip(prefix, 1)} tmp['subnets'].append(net) diff --git a/src/op_mode/dhcp.py b/src/op_mode/dhcp.py index dffd99de5..5a1351431 100755 --- a/src/op_mode/dhcp.py +++ b/src/op_mode/dhcp.py @@ -170,9 +170,9 @@ def _get_formatted_server_leases(raw_data, family='inet'): ipaddr = lease.get('ip') state = lease.get('state') start = lease.get('last_communication') - start = _utc_to_local(start).strftime('%Y/%m/%d %H:%M:%S') + start = _utc_to_local(start).strftime('%Y/%m/%d %H:%M:%S') end = lease.get('end') - end = _utc_to_local(end).strftime('%Y/%m/%d %H:%M:%S') + end = _utc_to_local(end).strftime('%Y/%m/%d %H:%M:%S') if end else '-' remain = lease.get('remaining') lease_type = lease.get('type') pool = lease.get('pool') |