Skip to content

Commit 8307757

Browse files
authored
Merge pull request #48 from smoors/desktop
use common xfce desktop for Desktop app
2 parents 05a4054 + 9b3251a commit 8307757

File tree

3 files changed

+17
-21
lines changed

3 files changed

+17
-21
lines changed

apps/vub_desktop/form.yml.erb

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,11 @@ attributes:
1313
required: true
1414
desktop: "xfce"
1515
resolution:
16-
widget: select
17-
label: "screen resolution"
18-
help: "This defines the resolution of your screen."
16+
widget: "select"
17+
label: "Screen resolution"
1918
options:
20-
- ["FullHD", "1920x1080"]
21-
- ["HD", "1280x720"]
19+
- ["FullHD (1920x1080)", "1920x1080"]
20+
- ["HD (1280x720)", "1280x720"]
2221
<%= ERB.new(File.read(File.expand_path("../common_files/_extra_attributes.yml.erb", __dir__)), eoutvar: "@common_attrs").result(binding) %>
2322

2423
form:

apps/vub_desktop/template/script.sh.erb

Lines changed: 10 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,18 @@
22

33
<%= ERB.new(File.read('../common_files/work_directory_change.sh.erb'), eoutvar: 'child').result(binding) %>
44

5-
# Ensure that the user's configured login shell is used
6-
export SHELL="$(getent passwd $USER | cut -d: -f7)"
5+
# Benchmark info
6+
echo "TIMING - Starting main script at: $(date)"
77

8-
if [ ${SLURM_GPUS_ON_NODE:-0} -gt 0 ]; then
9-
gpu_bus_id=$(nvidia-smi --query-gpu=gpu_bus_id --format=csv,noheader)
10-
# to lowercase
11-
gpu_bus_id=${gpu_bus_id,,}
12-
# Need to strip off first 4 zeros
13-
dri_device=$(ls -d /sys/bus/pci/devices/${gpu_bus_id:4}/drm/card*)
14-
export VGL_DISPLAY=/dev/dri/${dri_device##*/}
15-
export VGL_LOGO=1 # for testing
16-
echo "Setting VGL_DISPLAY to $VGL_DISPLAY"
17-
else
18-
export VGL_DISPLAY=$DISPLAY
19-
fi
8+
# Set VGL_DISPLAY to a GPU card if available, otherwise to Mesa llvmpipe
9+
<%= ERB.new(File.read('../common_files/oodegl.sh.erb'), eoutvar: 'child').result(binding) %>
10+
11+
<%- unless context.global_prerun.empty? -%>
12+
<%= context.global_prerun.gsub("\r", "") %>
13+
<%- end -%>
2014

2115
# Start up desktop
2216
echo "Launching desktop '<%= context.desktop %>'..."
23-
source "<%= session.staged_root.join("desktops", "#{context.desktop}.sh") %>"
17+
<%= ERB.new(File.read("../common_files/desktops/#{context.desktop}.sh.erb"), eoutvar: 'child').result(binding) %>
18+
2419
echo "Desktop '<%= context.desktop %>' ended with $? status..."

ondemand-vub.spec

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
Summary: Scripts, customizations and tools for Open OnDemand
55
Name: ondemand-vub
6-
Version: 2.06
6+
Version: 2.07
77
Release: 1
88
BuildArch: noarch
99
License: GPL
@@ -57,6 +57,8 @@ Scripts, customizations and tools for Open OnDemand as used at the VUB.
5757
/var/www/ood/apps/sys
5858

5959
%changelog
60+
* Sat Nov 15 2025 Samuel Moors <[email protected]>
61+
- Use common xfce desktop for Desktop app
6062
* Thu Nov 13 2025 Ward Poelmans <[email protected]>
6163
- Create bookmarks for VSC directories
6264
* Tue Nov 11 2025 Samuel Moors <[email protected]>

0 commit comments

Comments
 (0)