Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add entries for DRAC cluster during mila init [MT-61] #54

Merged
merged 48 commits into from
Jan 23, 2024

Conversation

lebrice
Copy link
Collaborator

@lebrice lebrice commented Aug 31, 2023

Asks the user if they also have access to the DRAC cluster. Adds the following block to the ssh config:

# Compute Canada
Host beluga cedar graham narval niagara
  Hostname %h.alliancecan.ca
  User {user}
Host mist
  Hostname mist.scinet.utoronto.ca
  User {user}
Host !beluga  bc????? bg????? bl?????
  ProxyJump beluga
  User {user}
Host !cedar   cdr? cdr?? cdr??? cdr????
  ProxyJump cedar
  User {user}
Host !graham  gra??? gra????
  ProxyJump graham
  User {user}
Host !narval  nc????? ng?????
  ProxyJump narval
  User {user}
Host !niagara nia????
  ProxyJump niagara
  User {user}

TODOs:

  • Checks for passwordless SSH aren't working correctly with DRAC clusters
  • There are too many empty lines in the generated config

@lebrice lebrice requested a review from breuleux September 14, 2023 16:57
@lebrice lebrice requested a review from satyaog September 22, 2023 20:36
@lebrice lebrice marked this pull request as draft September 25, 2023 18:59
@lebrice lebrice marked this pull request as ready for review November 6, 2023 18:30
@lebrice lebrice changed the title MT-61 Add entries for DRAC cluster during mila init Add entries for DRAC cluster during mila init [MT-61] Nov 28, 2023
@lebrice lebrice force-pushed the drac branch 2 times, most recently from 339abce to 59b145b Compare December 10, 2023 23:45
@codecov-commenter
Copy link

codecov-commenter commented Dec 18, 2023

Codecov Report

Attention: 46 lines in your changes are missing coverage. Please review.

Comparison is base (987a516) 55.74% compared to head (1202630) 58.99%.
Report is 3 commits behind head on master.

Files Patch % Lines
milatools/cli/init_command.py 71.53% 39 Missing ⚠️
milatools/cli/local.py 82.60% 4 Missing ⚠️
milatools/cli/commands.py 25.00% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master      #54      +/-   ##
==========================================
+ Coverage   55.74%   58.99%   +3.25%     
==========================================
  Files           9        9              
  Lines        1202     1268      +66     
==========================================
+ Hits          670      748      +78     
+ Misses        532      520      -12     
Flag Coverage Δ
unittests 58.99% <71.95%> (+3.25%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Fabrice Normandin <[email protected]>
Signed-off-by: Fabrice Normandin <[email protected]>
Signed-off-by: Fabrice Normandin <[email protected]>
Signed-off-by: Fabrice Normandin <[email protected]>
Signed-off-by: Fabrice Normandin <[email protected]>
Signed-off-by: Fabrice Normandin <[email protected]>
Signed-off-by: Fabrice Normandin <[email protected]>
Copy link
Member

@satyaog satyaog left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noticing that there's a lot of test files. Are all of the tests are necessary of if some of them could be removed? If so, no need to do this in this PR and an issue could be created. I was also wondering if a diff could encompass more info in less lines? For example, the with no initial ssh config file or with this initial content could become implicit in the formatting. This too could become an issue if it is though to bring value to the readability

Comment on lines 18 to 20
def display(self, args: list[str] | tuple[str, ...]) -> None:
print(T.bold_green("(local) $ ", shjoin(args)))
display(args)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we delete this method and only have the new display function?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I'm thinking of removing the Local and Remote classes in the longer term.

@lebrice lebrice merged commit 4adedbc into mila-iqia:master Jan 23, 2024
16 checks passed
@lebrice lebrice deleted the drac branch January 23, 2024 15:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants