Skip to content

Commit

Permalink
Merge pull request #36 from envato/containerIndex
Browse files Browse the repository at this point in the history
Be explicit that agent/container index is being requested
  • Loading branch information
andyjdavis authored Dec 31, 2024
2 parents c3d3001 + 195ec8e commit 98c2ec9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ task-three | i-456def456def456de | 4 | t3-container-one
| | 5 | t3-container-two
| | 6 | t3-container-three
Connect to which container?
Enter the INDEX number and press ENTER to connect:
```

Same with connecting directly to agents
Expand All @@ -179,7 +179,7 @@ INDEX | INSTANCE_ID | TASK | CONTAINER
| | | t3-container-two
| | | t3-container-three
Connect to which agent?
Enter the INDEX number and press ENTER to connect:
```

Both `connect_to_containers` and `connect_to_agents` can have the following optional arguments:
Expand Down
4 changes: 2 additions & 2 deletions lib/knuckle_cluster.rb
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ def select_agent(auto: false)

output_agents

puts "\nConnect to which agent?"
puts "\nEnter the INDEX number and press ENTER to connect:"
agents[STDIN.gets.strip.to_i - 1]
end

Expand All @@ -116,7 +116,7 @@ def select_container(auto: false)
{ index: { display_method: 'containers.index' } },
{ container: { display_method: 'containers.name', width: 999 } }

puts "\nConnect to which container?"
puts "\nEnter the INDEX number and press ENTER to connect:"
containers[STDIN.gets.strip.to_i - 1]
end

Expand Down

0 comments on commit 98c2ec9

Please sign in to comment.