cypress-example-docker-compose
cypress-example-docker-compose copied to clipboard
cypress interactive mode on a port of a ec2 Amazon Linux 2 machine
Hey. I've been trying to serve the cypress interactive mode on a port of a ec2 Amazon Linux 2 machine
I've follow unsuccesfully these examples
What I'm trying to achive is this:
- Run cypress interactive mode on a port of the ec2 machine
- Expose that port to the public
- Give a link to a non-tech QA colleage, where he/she can run and see the tests happening
Is this possible?
I've tried installing MATE desktop and the server, using Xvfb
Xvfb -screen 0 1920x1080x24 :99 & export DISPLAY=:99
and sending the Display variable to docker cypress images: included and base
also with TiggerVNC
I've tried to send X11-unix as a volume and also my dbus socket
docker run -it \
-v $PWD:/e2e \
-v /tmp/.X11-unix:/tmp/.X11-unix \
-w /e2e \
-e DISPLAY \
-v /var/run/dbus/system_bus_socket:/var/run/dbus/system_bus_socket \
--entrypoint cypress \
cypress/included:10.3.0 open
MAIN QUESTIONS:
Is the cypress:included the best image for this? Is it really possible?
Main errors?
The cypress GUI will not work without setting up display with IP.
Can you share your dockerfile and docker-compose?
Meanwhile, you can try this:
- In your docker-compose file, add the following in the volume of the cypress container:
~/.Xauthority:/root/.Xauthority:rw - In your Dockerfile:
Use image cypress/browsers and install the dependencies
RUN apt-get install libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libgconf-2-4 libnss3 libxss1 libasound2 libxtst6 xauth xvfb