Skip to content

Commit

Permalink
Vast: ssh port code fix
Browse files Browse the repository at this point in the history
  • Loading branch information
kristopolous committed Jan 22, 2025
1 parent f83d114 commit 6fc6a2b
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions sky/provision/vast/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,14 +140,4 @@ def get_ssh_ports(cluster_name: str) -> List[int]:
assert ssh_ports, (
f'Could not find any instances for cluster {cluster_name}.')

# So now we have
# [(name, port) ... ]
#
# We want to put head first and otherwise sort numerically
# and then extract the ports.
ssh_ports = list(
x[1]
for x in sorted(ssh_ports,
key=lambda x: -1
if x[0].endswith('head') else int(x[0].split('-')[-1])))
return ssh_ports

0 comments on commit 6fc6a2b

Please sign in to comment.