x11docker: Error response from daemon: Container XXX is not running [snap]

Environment: Intel NUC NUC7i5BNK - Ubuntu Server 18.04 - Xorg installed

Command: sudo x11docker --xorg x11docker/xfce xfce4-terminal

Log: https://pastebin.com/8nsJYGFf

Behavior: During the command execution I can see a gray screen with an black X in the middle of the screen. After the command fail, the console login screen is shown.

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 23 (14 by maintainers)

Commits related to this issue

Most upvoted comments

Some partial success!

This one works:

sudo x11docker --newprivileges --xoverip --xorg x11docker/fvwm xterm

It seems to me that snap / snappy does some containerization that disturbs access to some host files. --newprivileges allows to gain privileges a process did not have before. This is not needed for regular docker installations with e.g. apt. With this option the container user might be able to become root in container or to gain other privileges he should not have. --xoverip is an inofficial/experimental x11docker option that connects the application over TCP network instead of sharing the X unix socket. (Note that this does not work with --hostdisplay).

Overall I’d say that this is just a bad integration done by snap / snappy.

If there is a way to detect that docker is installed with snap or snappy, x11docker could show a warning and give a hint to use --newprivileges --xoverip. x11docker could also automatically set this along with a warning. Can you show me which docker? With snap it is:

$ which docker
/snap/bin/docker

Sorry to give this info just now… I didn’t realize that Ubuntu didn’t use apt to install docker during installation.

No worries. Why should one think that the package manager is the reason for an issue?