mirror of
https://github.com/kasmtech/workspaces-images.git
synced 2024-11-21 23:53:10 +01:00
Merge branch 'feature/KASM-2799_add_gpu_more_images' into 'develop'
Make firefox,brave,edge GPU capable Closes KASM-2799 See merge request kasm-technologies/internal/workspaces-images!61
This commit is contained in:
commit
2c6f1b824a
@ -24,7 +24,13 @@ cat >/usr/bin/brave-browser <<EOL
|
||||
#!/usr/bin/env bash
|
||||
sed -i 's/"exited_cleanly":false/"exited_cleanly":true/' ~/.config/BraveSoftware/Brave-Browser/Default/Preferences
|
||||
sed -i 's/"exit_type":"Crashed"/"exit_type":"None"/' ~/.config/BraveSoftware/Brave-Browser/Default/Preferences
|
||||
/opt/brave.com/brave/brave-browser ${CHROME_ARGS} "\$@"
|
||||
if [ -f /opt/VirtualGL/bin/vglrun ] && [ ! -z "\${KASM_EGL_CARD}" ] && [ ! -z "\${KASM_RENDERD}" ] && [ -O "\${KASM_RENDERD}" ] && [ -O "\${KASM_EGL_CARD}" ] ; then
|
||||
echo "Starting Brave with GPU Acceleration on EGL device \${KASM_EGL_CARD}"
|
||||
vglrun -d "\${KASM_EGL_CARD}" /opt/brave.com/brave/brave-browser ${CHROME_ARGS} "\$@"
|
||||
else
|
||||
echo "Starting Brave"
|
||||
/opt/brave.com/brave/brave-browser ${CHROME_ARGS} "\$@"
|
||||
fi
|
||||
EOL
|
||||
chmod +x /usr/bin/brave-browser
|
||||
cp /usr/bin/brave-browser /usr/bin/brave
|
||||
|
@ -19,7 +19,13 @@ cat >/usr/bin/microsoft-edge-dev <<EOL
|
||||
#!/usr/bin/env bash
|
||||
sed -i 's/"exited_cleanly":false/"exited_cleanly":true/' ~/.config/microsoft-edge-dev/Default/Preferences
|
||||
sed -i 's/"exit_type":"Crashed"/"exit_type":"None"/' ~/.config/microsoft-edge-dev/Default/Preferences
|
||||
/opt/microsoft/msedge-dev/microsoft-edge ${CHROME_ARGS} "\$@"
|
||||
if [ -f /opt/VirtualGL/bin/vglrun ] && [ ! -z "\${KASM_EGL_CARD}" ] && [ ! -z "\${KASM_RENDERD}" ] && [ -O "\${KASM_RENDERD}" ] && [ -O "\${KASM_EGL_CARD}" ] ; then
|
||||
echo "Starting Edge with GPU Acceleration on EGL device \${KASM_EGL_CARD}"
|
||||
vglrun -d "\${KASM_EGL_CARD}" /opt/microsoft/msedge-dev/microsoft-edge ${CHROME_ARGS} "\$@"
|
||||
else
|
||||
echo "Starting Edge"
|
||||
/opt/microsoft/msedge-dev/microsoft-edge ${CHROME_ARGS} "\$@"
|
||||
fi
|
||||
EOL
|
||||
chmod +x /usr/bin/microsoft-edge-dev
|
||||
|
||||
|
@ -25,6 +25,11 @@ done
|
||||
|
||||
FORCE=$2
|
||||
|
||||
# run with vgl if GPU is available
|
||||
if [ -f /opt/VirtualGL/bin/vglrun ] && [ ! -z "${KASM_EGL_CARD}" ] && [ ! -z "${KASM_RENDERD}" ] && [ -O "${KASM_RENDERD}" ] && [ -O "${KASM_EGL_CARD}" ] ; then
|
||||
START_COMMAND="/opt/VirtualGL/bin/vglrun -d ${KASM_EGL_CARD} $START_COMMAND"
|
||||
fi
|
||||
|
||||
kasm_exec() {
|
||||
if [ -n "$OPT_URL" ] ; then
|
||||
URL=$OPT_URL
|
||||
|
Loading…
Reference in New Issue
Block a user