diff --git a/Dockerfile b/Dockerfile
index fafe483..25a4fc4 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -358,6 +358,7 @@ RUN \
-e 's/NLIMC/NLMC/g' \
-e '/debian-menu/d' \
-e 's|| yes\n|' \
+ -e 's|| \n|' \
/etc/xdg/openbox/rc.xml && \
echo "**** user perms ****" && \
sed -e 's/%sudo ALL=(ALL:ALL) ALL/%sudo ALL=(ALL:ALL) NOPASSWD: ALL/g' \
diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64
index f153309..44fa946 100644
--- a/Dockerfile.aarch64
+++ b/Dockerfile.aarch64
@@ -360,6 +360,7 @@ RUN \
-e 's/NLIMC/NLMC/g' \
-e '/debian-menu/d' \
-e 's|| yes\n|' \
+ -e 's|| \n|' \
/etc/xdg/openbox/rc.xml && \
echo "**** user perms ****" && \
sed -e 's/%sudo ALL=(ALL:ALL) ALL/%sudo ALL=(ALL:ALL) NOPASSWD: ALL/g' \
diff --git a/root/etc/s6-overlay/s6-rc.d/svc-kasmvnc/run b/root/etc/s6-overlay/s6-rc.d/svc-kasmvnc/run
index 9634762..aebd469 100755
--- a/root/etc/s6-overlay/s6-rc.d/svc-kasmvnc/run
+++ b/root/etc/s6-overlay/s6-rc.d/svc-kasmvnc/run
@@ -1,7 +1,7 @@
#!/usr/bin/with-contenv bash
# Pass gpu flags if mounted
-if ls /dev/dri/renderD* 1> /dev/null 2>&1; then
+if ls /dev/dri/renderD* 1> /dev/null 2>&1 && [ -z ${DISABLE_DRI+x} ]; then
HW3D="-hw3d"
fi
if [ -z ${DRINODE+x} ]; then