Ensure Xvfb
is only started once the watcher is running
This commit is contained in:
parent
0dbb721635
commit
848754d84a
1 changed files with 3 additions and 1 deletions
|
@ -127,8 +127,10 @@ RUN \
|
|||
export DISPLAY=$display; \
|
||||
mkdir -p --mode=777 /tmp/.X11-unix; \
|
||||
# Create job for waiting for Xvfb to start
|
||||
{ inotifywait -e create /tmp/.X11-unix/ 2>&1 > /dev/null & }; \
|
||||
watchStarting="$(mktemp)"; \
|
||||
{ 2>&1 inotifywait -e create /tmp/.X11-unix/; } | { sed -u -e "/^Watches established.\$/e rm \"$watchStarting\""; } & \
|
||||
resolver=$!; \
|
||||
while [ -f "$watchStarting" ]; do true; done; \
|
||||
{ \
|
||||
# Improve arguments for screenshots
|
||||
ARGS=$([ $DEBUG -eq 1 ] && echo "-screen 0 640x480x24 -dpi 192" || echo ""); \
|
||||
|
|
Loading…
Reference in a new issue