Closed Gilsaa closed 4 years ago
So, I figured it out. The .Xauthority file should be put in the home of the user specified in the docker run command, ie. --volume="$HOME/.Xauthority:/home/docker/.Xauthority:rw.
Therefore if a user is specified the run command will look like this;
docker run -it --rm --name ros_kinetic \
--net=host \
--privileged \
--volume="$DRONE_LAB_DIR:/DroneLab" \
--volume="$DRONE_LAB_DIR:/dockers/docker_home:/home/docker" \
--volume="$DRONE_LAB_DIR:/ros/catkin_ws:/ros/catkin_ws" \
--volume="$HOME/.Xauthority:/home/docker/.Xauthority:rw" \
--env="DISPLAY" \
--env="USERNAME=docker" \
--env="USER=docker" \
--env="HOME=/home/docker" \
ros_image_kinetic "bin/bash" $@
Now to fix the issues caused by using a nVidia driver instead of the nouveua ...
Thanks for the update
Hi, I've installed the software on a remote server and want to SSH into this server and see the simulation. However when I run runtmux_game_docker.sh from PX4_Gazebo I don't see any screens. The error message says "X11 connection rejected because of wrong authentication".
The $DISPLAY variable is set correctly. I can use xeyes on the server and the forwarding works. I can use xeyes in a simple Docker container and it works.
Simple Docker - Dockerfile
Simple Docker - run.sh
There seems to be a problem with the X11 forwardning between the Docker host and container. Do you have any ideas how to fix this? Or which files to possibly change? I've tried changing the ros_image_kinetic run_image.sh to look more like the simple docker example, but it doesn't work.