Skip to content

Commit

Permalink
sleep and -it
Browse files Browse the repository at this point in the history
  • Loading branch information
consideRatio committed Mar 29, 2024
1 parent 7273e56 commit 71de07d
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@ jobs:
- name: Test vncserver
if: always()
run: |
container_id=$(docker run -d -p 5901:5901 test vncserver -xstartup /opt/install/jupyter_remote_desktop_proxy/share/xstartup -verbose -fg -geometry 1680x1050 -SecurityTypes None -rfbport 5901)
sleep 1
container_id=$(docker run -d -it -p 5901:5901 test vncserver -xstartup /opt/install/jupyter_remote_desktop_proxy/share/xstartup -verbose -fg -geometry 1680x1050 -SecurityTypes None -rfbport 5901)
sleep 3
timeout --preserve-status 1 nc -v 127.0.0.1 5901 2>&1 | \
timeout --preserve-status 1 nc -v localhost 5901 2>&1 | \
grep --quiet RFB && echo "Passed test" || { echo "Failed test" && TEST_OK=false; }
echo "::group::vncserver logs"
Expand All @@ -77,10 +77,10 @@ jobs:
- name: Test websockify'ed vncserver
if: always()
run: |
container_id=$(docker run -d -p 5901:5901 test websockify --verbose --log-file=/tmp/websockify.log --heartbeat=30 5901 -- vncserver -xstartup /opt/install/jupyter_remote_desktop_proxy/share/xstartup -verbose -fg -geometry 1680x1050 -SecurityTypes None -rfbport 5901)
sleep 1
container_id=$(docker run -d -it -p 5901:5901 test websockify --verbose --log-file=/tmp/websockify.log --heartbeat=30 5901 -- vncserver -xstartup /opt/install/jupyter_remote_desktop_proxy/share/xstartup -verbose -fg -geometry 1680x1050 -SecurityTypes None -rfbport 5901)
sleep 3
websocat --binary --one-message --exit-on-eof "ws://127.0.0.1:5901/" 2>&1 | \
websocat --binary --one-message --exit-on-eof "ws://localhost:5901/" 2>&1 | \
grep --quiet RFB && echo "Passed test" || { echo "Failed test" && TEST_OK=false; }
echo "::group::websockify logs"
Expand All @@ -100,7 +100,7 @@ jobs:
- name: Test project's proxy to websockify'ed vncserver
if: always()
run: |
container_id=$(docker run -d -p 8888:8888 -e JUPYTER_TOKEN=secret test)
container_id=$(docker run -d -it -p 8888:8888 -e JUPYTER_TOKEN=secret test)
sleep 3
curl --silent --fail 'http://localhost:8888/desktop/?token=secret' | grep --quiet 'Jupyter Remote Desktop Proxy' && echo "Passed get index.html test" || { echo "Failed get index.html test" && TEST_OK=false; }
Expand Down

0 comments on commit 71de07d

Please sign in to comment.