Skip to content

Commit

Permalink
Merge pull request #210 from SouthernMethodistUniversity/ood_slurm_ac…
Browse files Browse the repository at this point in the history
…counts

Ood slurm accounts
  • Loading branch information
jrlagrone authored Aug 21, 2024
2 parents 8f58fc1 + 15cfbe2 commit c8338e6
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 14 deletions.
12 changes: 5 additions & 7 deletions ood/combined_desktop/form.yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@ cluster: "m3cluster"
submit: submit.yml.erb

form:
<%- if CheckAccounts.Accounts.length() > 1 -%>
- slurm_accounts
<%- end -%>
- custom_queues
- desktop_os
- desktop_env
Expand All @@ -29,19 +27,19 @@ form:
- email_on_start

attributes:
<%- if CheckAccounts.Accounts.length() > 1 -%>
slurm_accounts:
widget: select
label: "Slurm Account"
help: |
Select a Slurm account. By default all users have a default "smu" account.
You may have other accounts, e.g. to access course specific material or
special allocations.
Select a Slurm account.
Slurm accounts grant to access allocations and/or course specific material.
**Important:** beginning on November 1, 2024. The Slurm account *smu* will
be disabled. Only Slurm accounts allocated with [ColdFront] will be usable.
[ColdFront]: https://hpcaccess.smu.edu
options:
<%- CheckAccounts.Accounts.each do |q| -%>
- [ "<%= q %>", "<%= q %>" ]
<%- end -%>
<%- end -%>
custom_queues:
label: "Partition"
widget: select
Expand Down
1 change: 1 addition & 0 deletions ood/jupyterlab/CheckAccounts.rb
17 changes: 17 additions & 0 deletions ood/jupyterlab/form.yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,15 @@ require_relative "CheckQueues"
# find user conda environments
require_relative "CustomEnvironments"

# find slurm accounts
require_relative "CheckAccounts"

-%>

---
cluster: "m3cluster"
form:
- slurm_accounts
- custom_queues
- python_version
- build_environment
Expand All @@ -28,6 +32,19 @@ form:
# Define attribute values that aren't meant to be modified by the user within
# the Dashboard form
attributes:
slurm_accounts:
widget: select
label: "Slurm Account"
help: |
Select a Slurm account.
Slurm accounts grant to access allocations and/or course specific material.
**Important:** beginning on November 1, 2024. The Slurm account *smu* will
be disabled. Only Slurm accounts allocated with [ColdFront] will be usable.
[ColdFront]: https://hpcaccess.smu.edu
options:
<%- CheckAccounts.Accounts.each do |q| -%>
- [ "<%= q %>", "<%= q %>" ]
<%- end -%>
custom_queues:
label: "Partition"
widget: select
Expand Down
4 changes: 4 additions & 0 deletions ood/jupyterlab/submit.yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,7 @@ script:
- "--mail-type"
- "BEGIN"
<%- end -%>
<%- if defined?slurm_accounts -%>
- "-A"
- "<%= slurm_accounts %>"
<%- end -%>
12 changes: 5 additions & 7 deletions ood/rstudio/form.yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@ require_relative "CheckAccounts"
---
cluster: "m3cluster"
form:
<%- if CheckAccounts.Accounts.length() > 1 -%>
- slurm_accounts
<%- end -%>
- r_module
- environment
- custom_queues
Expand All @@ -23,19 +21,19 @@ form:
- bc_num_gpus
- email_on_start
attributes:
<%- if CheckAccounts.Accounts.length() > 1 -%>
slurm_accounts:
widget: select
label: "Slurm Account"
help: |
Select a Slurm account. By default all users have a default "smu" account.
You may have other accounts, e.g. to access course specific material or
special allocations.
Select a Slurm account.
Slurm accounts grant to access allocations and/or course specific material.
**Important:** beginning on November 1, 2024. The Slurm account *smu* will
be disabled. Only Slurm accounts allocated with [ColdFront] will be usable.
[ColdFront]: https://hpcaccess.smu.edu
options:
<%- CheckAccounts.Accounts.each do |q| -%>
- [ "<%= q %>", "<%= q %>" ]
<%- end -%>
<%- end -%>
r_module:
widget: select
label: "R Version"
Expand Down
4 changes: 4 additions & 0 deletions ood/rstudio/submit.yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,7 @@ script:
- "--mail-type"
- "BEGIN"
<%- end -%>
<%- if defined?slurm_accounts -%>
- "-A"
- "<%= slurm_accounts %>"
<%- end -%>

0 comments on commit c8338e6

Please sign in to comment.