Skip to content

Xauthority on Ubuntu 22 #1

@ljburtz

Description

@ljburtz

Summary:
tested that it works on Ubuntu 22.04 (with two additional commands)
5.15.0-39-generic
Docker version 20.10.17, build 100c701

Details:
with the README instructions I did not have any turtlesim window open
inspecting the docker container and running turtlesim manually, I saw the following error message:

$ rosrun turtlesim turtlesim_node
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
Authorization required, but no authorization protocol specified
qt.qpa.screen: QXcbConnection: Could not connect to display :0
Could not connect to any X display.

commands that fixed it on the host:

xhost +local:docker
docker run --rm --interactive --tty --env DISPLAY=$DISPLAY --env XAUTHORITY=/tmp/.docker.xauth --net host --name easyturtle easyturtle

note the additional XAUTHORITY. I think it shouldn't hurt even on the environments where it was working without

@ic i can update the README.md if you wish

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions