Skip to content

Commit 145c71a

Browse files
author
Hoisko Sakari.M 10802213
committed
Taked noVNC to use, just browser needed to remote desctop connection
1 parent 73395ce commit 145c71a

File tree

3 files changed

+20
-18
lines changed

3 files changed

+20
-18
lines changed

README.md

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -79,22 +79,20 @@ java -cp "target/javafxlibrary-<version>.jar" org.robotframework.RobotFramework
7979
8080
## Remote library demo with Docker
8181
### Requirements:
82-
* VNC viewer e.g. https://www.realvnc.com/en/connect/download/viewer/
8382
* Docker CE: https://docs.docker.com/install/
8483
* Docker-compose: https://docs.docker.com/compose/install/
85-
* VNC port: vnc://localhost:5900
84+
* Port 80 is free in your machine
8685
8786
### Running the demo with testing env
8887
1. Build & Start Dockerized Environment: `docker-compose up -d robot-framework javafxcompile`
89-
2. Take VNC connection to: <i>vnc://<docker_daemon_ip>:5900</i>
90-
3. Password is: 1234
91-
4. Open shell by right clicking in VNC desktop and selecting Applications > Shells > Bash
92-
5. Execute tests: `test.sh`
88+
2. Open browser to <docker_daemon_ip>
89+
3. Open xterm from start menu > System tools > xterm
90+
4. Execute tests in xterm window: `test.sh`
9391
9492
FYI:
95-
Single testcase execution in locale and remote (replace spaces with _ ):<br>
96-
`test.sh all '--include tag_name' '-t test_case_name'`<br>
97-
Single suite execution in locale and remote (replace spaces with _ ):<br>
98-
`test.sh all '--include tag_name' '-s suite_name'`
93+
Single testcase execution in locale|remote|all (replace spaces in testcase name with _ ):<br>
94+
`test.sh locale '--include tag_name' '-t test_case_name'`<br>
95+
Single suite execution in locale and remote (replace spacesin test suite name with _ ):<br>
96+
`test.sh remote '--include tag_name' '-s suite_name'`
9997
<br>
10098
NOTE: smoke tag is default included.

docker-compose.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,17 @@ services:
55
build:
66
context: ./docker/robot-javafx-demo
77
ports:
8-
- '5900:5900'
8+
#- '5900:5900'
9+
- '80:80'
910
volumes:
1011
- './src/test/robotframework/:/robot'
1112
- screen-thing:/tmp/.X11-unix
1213
- './src/:/src' # ScreenCapturingTest.robot require this.
1314
- javafxbinaryshare:/javafxbinary
1415
networks:
1516
- testapp
17+
environment:
18+
- RESOLUTION=1027x768
1619

1720
javafxcompile:
1821
build:
@@ -27,7 +30,7 @@ services:
2730
- screen-thing:/tmp/.X11-unix
2831
- javafxbinaryshare:/javafxbinary
2932
environment:
30-
- DISPLAY=:20.0
33+
- DISPLAY=:1
3134

3235
# javafxrelease:
3336
# build:

docker/robot-javafx-demo/Dockerfile

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM ubuntu:16.04
1+
FROM dorowu/ubuntu-desktop-lxde-vnc
22

33
ENV DEBIAN_FRONTEND noninteractive
44

@@ -24,9 +24,10 @@ RUN apt-get -qq update && apt-get dist-upgrade -y && apt-get install -qq --no-i
2424
RUN pip install --no-cache-dir \
2525
robotframework
2626

27-
COPY entrypoint.sh /entrypoint.sh
27+
#COPY entrypoint.sh /entrypoint.sh
2828
COPY test.sh /bin/test.sh
29-
RUN mkdir ~/.vnc && x11vnc -storepasswd 1234 ~/.vnc/passwd && chmod 555 /entrypoint.sh /bin/test.sh
30-
EXPOSE 5900
31-
32-
ENTRYPOINT ["x11vnc", "-create", "-forever", "-env", "FD_PROG=/entrypoint.sh", "-env", "X11VNC_CREATE_GEOM=${1:-1024x768x16}", "-usepw"]
29+
RUN chmod 555 /bin/test.sh
30+
#RUN mkdir ~/.vnc && x11vnc -storepasswd 1234 ~/.vnc/passwd && chmod 555 /entrypoint.sh /bin/test.sh
31+
EXPOSE 5900 6080
32+
#ENTRYPOINT ["x11vnc", "-create", "-forever", "-env", "FD_PROG=/entrypoint.sh", "-env", "X11VNC_CREATE_GEOM=${1:-1024x768x16}", "-usepw"]
33+
ENTRYPOINT ["/startup.sh"]

0 commit comments

Comments
 (0)