saalfeldlab / render

Render transformed image tiles
GNU General Public License v2.0
34 stars 32 forks source link

sporadic dockerfile build failure after chmod #87

Closed djkapner closed 6 years ago

djkapner commented 6 years ago

this happens on one machine, but not on another... not sure why, but other docker users have reported the same sporadic problem as well: https://github.com/moby/moby/issues/9547

/var/lib/jetty/webapps:
total 12
drwxrwxrwx  2 root  root  4096 May 22 21:34 .
drwxr-xr-x 12 jetty jetty 4096 May 23 00:04 ..
-rwxrwxr-x  1 root  root   431 May 22 21:34 root-context.xml
/bin/sh: ./configure_web_server.sh: Text file busy
The command '/bin/sh -c ls -al $JETTY_BASE/* &&     chmod 755 ./configure_web_server.sh &&     ./configure_web_server.sh' returned a non-zero code: 2

either of these 2 changes to the dockerfile fix the problem:

RUN ls -al $JETTY_BASE/* && \
    chmod 755 ./configure_web_server.sh && \
    sync && \
    ./configure_web_server.sh

or

RUN ls -al $JETTY_BASE/* && \
    chmod 755 ./configure_web_server.sh && \
    sleep 2 && \
    ./configure_web_server.sh