Fix race condition
This commit is contained in:
parent
38957d1da3
commit
ad84480c10
@ -8,6 +8,7 @@ RUN sudo pacman -Syuq --noconfirm
|
||||
|
||||
# Install KASM VNC server
|
||||
RUN paru -S --noconfirm kasmvncserver-bin
|
||||
ENV DISPLAY=:1
|
||||
|
||||
# KASM requires the hostname binary to start
|
||||
RUN sudo pacman -S --noconfirm inetutils
|
||||
|
@ -2,12 +2,18 @@
|
||||
cd /home/designer
|
||||
|
||||
# Run VNC server
|
||||
export DISPLAY=:1
|
||||
eval $(vncserver -dry-run) &
|
||||
echo -e "password\npassword\n" | vncpasswd -u designer -w -r
|
||||
|
||||
# Wait for VNC server to start
|
||||
sleep 1
|
||||
sleep 2
|
||||
while ! xset q &>/dev/null;
|
||||
do
|
||||
echo "XServer not responsive, retrying..."
|
||||
sleep 2
|
||||
done
|
||||
|
||||
echo "XServer has been found, running desktop environment"
|
||||
|
||||
# Run desktop environment (XFCE)
|
||||
xfce4-session --display=$DISPLAY
|
||||
|
Loading…
Reference in New Issue
Block a user