Skip to content

Commit

Permalink
[sonic-cfggen] Allow cfggen to work on system without ports
Browse files Browse the repository at this point in the history
Signed-off-by: liora <[email protected]>
  • Loading branch information
liorghub committed Jul 28, 2021
1 parent db76a6f commit fd1f5ce
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/sonic-config-engine/sonic-cfggen
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,9 @@ def main():
if args.port_config is None:
args.port_config = device_info.get_path_to_port_config_file(hwsku)
(ports, _, _) = get_port_config(hwsku, platform, args.port_config, asic_id)
if ports is None:
print('Failed to get port config', file=sys.stderr)
sys.exit(1)
deep_update(data, {'PORT': ports})

brkout_table = get_breakout_mode(hwsku, platform, args.port_config)
Expand Down

0 comments on commit fd1f5ce

Please sign in to comment.