Skip to content

Commit

Permalink
add cardinal to lw desktops - and remove Gnome as an option (#262)
Browse files Browse the repository at this point in the history
  • Loading branch information
johrstrom authored Oct 4, 2024
1 parent b1e1e02 commit 8844d7a
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 10 deletions.
1 change: 0 additions & 1 deletion apps.awesim.org/apps/bc_desktop/cardinal.yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ attributes:
options:
- ["Xfce", "xfce"]
- ["Mate", "mate"]
- ["Gnome", "gnome"]
help: |
This will launch either the [Xfce] or [Mate] desktop environment on the
[Cardinal cluster].
Expand Down
10 changes: 7 additions & 3 deletions apps.awesim.org/apps/bc_desktop/submit/vdi.yml.erb
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
<%-
args = [ "--partition", "quick", "--nodes", "1", "--ntasks-per-node", "1" ]
args.concat ["--licenses", "#{licenses}"] unless licenses.empty?

container_lookup = {
'ascend-login' => '/apps/project/ondemand/singularity/mate-rhel8/mate-rhel8.sif',
'cardinal-login' => '/apps/project/ondemand/lightdesktop_base/rhel9/rhel9.sif'
}
-%>
---
batch_connect:
Expand All @@ -9,19 +14,18 @@ batch_connect:
[[ $(type -t module) == "function" ]] && export -f module

# MATE doesn't like /var/run/$(id -u) and ascend-login doesn't have $TMPDIR
export XDG_RUNTIME_DIR="<%= cluster == 'ascend-login' ? '/tmp' : '$TMPDIR' %>/xdg_runtime"
export XDG_RUNTIME_DIR="<%= ['ascend-login', 'cardinal-login'].include?(cluster) ? '/tmp' : '$TMPDIR' %>/xdg_runtime"

# reset SLURM_EXPORT_ENV so that things like srun & sbatch work out of the box
export SLURM_EXPORT_ENV=ALL

script:
job_environment:
XDG_RUNTIME_DIR: "/tmp/xdg_runtime"
SINGULARITY_ENVXDG_RUNTIME_DIR: "/tmp/xdg_runtime"
APPTAINER_ENVXDG_RUNTIME_DIR: "/tmp/xdg_runtime"
native:
<%- if ['ascend-login', 'cardinal-login'].include?(cluster) -%>
singularity_container: "/apps/project/ondemand/singularity/mate-rhel8/mate-rhel8.sif"
singularity_container: "<%= container_lookup[cluster] %>"
singularity_bindpath: "/run,/apps"
<%- else -%>
<%- args.each do |arg| -%>
Expand Down
7 changes: 6 additions & 1 deletion apps.awesim.org/apps/bc_desktop/vdi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,18 @@ attributes:
- "owens"
- "pitzer"
- ["ascend", "ascend-login" ]
- ["cardinal", "cardinal-login" ]
desktop:
widget: select
label: "Desktop environment"
options:
- ["Xfce", "xfce"]
- ["Mate", "mate"]
- ["Gnome", "gnome", data-option-for-cluster-ascend-login: false ]
- [
"Gnome", "gnome",
data-option-for-cluster-ascend-login: false,
data-option-for-cluster-cardinal-login: false,
]
help: |
This will launch either the [Xfce] or [Mate] desktop environment on the
[Owens] or [Pitzer] clusters.
Expand Down
1 change: 0 additions & 1 deletion ondemand.osc.edu/apps/bc_desktop/cardinal.yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ attributes:
options:
- ["Xfce", "xfce"]
- ["Mate", "mate"]
- ["Gnome", "gnome"]
help: |
This will launch either the [Xfce] or [Mate] desktop environment on the
[Cardinal cluster].
Expand Down
10 changes: 7 additions & 3 deletions ondemand.osc.edu/apps/bc_desktop/submit/vdi.yml.erb
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
<%-
args = [ "--partition", "quick", "--nodes", "1", "--ntasks-per-node", "1" ]
args.concat ["--licenses", "#{licenses}"] unless licenses.empty?

container_lookup = {
'ascend-login' => '/apps/project/ondemand/singularity/mate-rhel8/mate-rhel8.sif',
'cardinal-login' => '/apps/project/ondemand/lightdesktop_base/rhel9/rhel9.sif'
}
-%>
---
batch_connect:
Expand All @@ -9,19 +14,18 @@ batch_connect:
[[ $(type -t module) == "function" ]] && export -f module

# MATE doesn't like /var/run/$(id -u) and ascend-login doesn't have $TMPDIR
export XDG_RUNTIME_DIR="<%= cluster == 'ascend-login' ? '/tmp' : '$TMPDIR' %>/xdg_runtime"
export XDG_RUNTIME_DIR="<%= ['ascend-login', 'cardinal-login'].include?(cluster) ? '/tmp' : '$TMPDIR' %>/xdg_runtime"

# reset SLURM_EXPORT_ENV so that things like srun & sbatch work out of the box
export SLURM_EXPORT_ENV=ALL

script:
job_environment:
XDG_RUNTIME_DIR: "/tmp/xdg_runtime"
SINGULARITY_ENVXDG_RUNTIME_DIR: "/tmp/xdg_runtime"
APPTAINER_ENVXDG_RUNTIME_DIR: "/tmp/xdg_runtime"
native:
<%- if ['ascend-login', 'cardinal-login'].include?(cluster) -%>
singularity_container: "/apps/project/ondemand/singularity/mate-rhel8/mate-rhel8.sif"
singularity_container: "<%= container_lookup[cluster] %>"
singularity_bindpath: "/run,/apps"
<%- else -%>
<%- args.each do |arg| -%>
Expand Down
7 changes: 6 additions & 1 deletion ondemand.osc.edu/apps/bc_desktop/vdi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,18 @@ attributes:
- "owens"
- "pitzer"
- ["ascend", "ascend-login" ]
- ["cardinal", "cardinal-login" ]
desktop:
widget: select
label: "Desktop environment"
options:
- ["Xfce", "xfce"]
- ["Mate", "mate"]
- ["Gnome", "gnome", data-option-for-cluster-ascend-login: false ]
- [
"Gnome", "gnome",
data-option-for-cluster-ascend-login: false,
data-option-for-cluster-cardinal-login: false,
]
help: |
This will launch either the [Xfce] or [Mate] desktop environment on the
[Owens] or [Pitzer] clusters.
Expand Down

0 comments on commit 8844d7a

Please sign in to comment.