mviereck / dockerfile-x11docker-deepin

3D desktop deepin from China
MIT License
33 stars 11 forks source link

Running the self-build wechat docker image in x11docker's desktop mode via '--desktop' option. #14

Closed hongyi-zhao closed 3 years ago

hongyi-zhao commented 3 years ago

Hi,

I Use the following Dockerfile to create the docker image named as x11docker-deepin-wechat:

$ grep -Ev '^[ ]*(#|$)' Dockerfile 
FROM x11docker/deepin
RUN echo "deb http://packages.deepin.com/deepin/ lion main non-free contrib" > /etc/apt/sources.list
RUN env DEBIAN_FRONTEND=noninteractive dpkg --add-architecture i386 && apt-get update
RUN env DEBIAN_FRONTEND=noninteractive apt-get install -y \
    apt-utils deepin-wine deepin-wine32 deepin-wine32-preloader deepin-wine-helper deepin-wine-uninstaller
RUN env DEBIAN_FRONTEND=noninteractive apt-get install -y deepin.com.wechat

The command used to create the image in the directory where the Dockerfile resides:

$ docker build -t x11docker-deepin-wechat .

I noticed some warnings/abnormal info as below:

debconf: delaying package configuration, since apt-utils is not installed
[...]
Adding group `uuidd' (GID 112) ...
Done.
Warning: The home dir /run/uuidd you specified can't be accessed: No such file or directory
Adding system user `uuidd' (UID 109) ...
Adding new user `uuidd' (UID 109) with group `uuidd' ...
Not creating home directory `/run/uuidd'.
Created symlink /etc/systemd/system/sockets.target.wants/uuidd.socket → /lib/systemd/system/uuidd.socket.
invoke-rc.d: could not determine current runlevel
invoke-rc.d: WARNING: No init system and policy-rc.d missing! Defaulting to block.

Any hints for eliminating/fixing them?

OTOH, even I've created the image successfully, I still can't run it with any of the following commands:

$ x11docker --sudouser --nxagent --clipboard x11docker-deepin-wechat
x11docker WARNING: User werner is member of group docker.
  That allows unprivileged processes on host to gain root privileges.

x11docker note: Sharing picture clips with option --clipboard
  is only possible with options --xpra, --xpra-xwayland and --hostdisplay.

x11docker note: A few applications do not work well with --nxagent.
  In that case, please try another X server option like --xephyr or --xpra.

x11docker WARNING: Option --sudouser severly reduces container security.
  Container gains additional capabilities to allow sudo and su.
  If an application breaks out of container, it can harm your system
  in many ways without you noticing. Password: x11docker

x11docker note: Option --sudouser: Enabling option --newprivileges=yes.
  You can avoid this with --newprivileges=no

x11docker WARNING: Option --newprivileges=yes: x11docker does not set 
  docker run option --security-opt=no-new-privileges. 
  That degrades container security.
  However, this is still within a default docker setup.

backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
Gkr-Message: secret service operation failed: Failed to execute program org.freedesktop.secrets: Operation not permitted

** (process:128): WARNING **: Failed to get default keyring: 6
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x58 pc=0x613a32]

goroutine 69 [running]:
pkg.deepin.io/lib/dbus1.(*Conn).getSerial(0x0, 0xc4201d17d0)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/conn.go:273 +0x22
pkg.deepin.io/lib/dbus1.(*Object).createCall(0xc42029b4d0, 0x7f4e506f7040, 0xc4200160a0, 0xc4201d8400, 0x34, 0x0, 0xc4201d2c00, 0xc4201db410, 0x1, 0x1, ...)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:135 +0xf6
pkg.deepin.io/lib/dbus1.(*Object).Go(0xc42029b4d0, 0xc4201d8400, 0x34, 0x0, 0xc4201d2c00, 0xc4201db410, 0x1, 0x1, 0x34)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:115 +0xbf
pkg.deepin.io/lib/dbusutil/proxy.(*Object).Go_(0xc42029b4a0, 0xc4201d8400, 0x34, 0x86e100, 0xc4201d2c00, 0xc4201db410, 0x1, 0x1, 0xc4201d6a01)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbusutil/proxy/object.go:57 +0x85
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).GoMarkLaunched(0xc42029b4a0, 0x0, 0xc4201d2c00, 0xc420415c00, 0x39, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:102 +0x122
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).MarkLaunched(0xc42029b4a0, 0xc420415c00, 0xc420415c00, 0x39, 0x0, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:106 +0x65
main.(*StartManager).launchAppWithOptions(0xc4202f8410, 0xc420415c00, 0x39, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2, 0xc4202f27d0)
    /build/startdde-3.14.7/startmanager.go:238 +0x2df
main.startAutostartProgram.func1(0xc420415c00, 0x39)
    /build/startdde-3.14.7/startmanager.go:912 +0xf9
created by main.startAutostartProgram
    /build/startdde-3.14.7/startmanager.go:903 +0x77
<warning> sound_effect.go:58: open /etc/lightdm/lightdm.conf: no such file or directory
<warning> brightness.go:154: failed to set brightness to 1 for default: The output(172) has invalid gamma size
<warning> manager.go:619: The output(172) has invalid gamma size
<info> manager.go:630: [updateMonitors] add monitor: default 0 0 1920 1080
<warning> config_version.go:47: Failed to delete config: remove /home/werner/.config/deepin/startdde/display.json: no such file or directory
<warning> brightness.go:154: failed to set brightness to 1 for default: The output(172) has invalid gamma size
<warning> brightness.go:138: The output(172) has invalid gamma size
<error> xsettings.go:243: Start xsettings failed: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
  ->  main.go:98
  ->  proc.go:198
  ->  asm_amd64.s:2361
<warning> main.go:101: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session.go:293: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session.go:509: exec gnome-keyring-daemon err: fork/exec /usr/bin/gnome-keyring-daemon: operation not permitted
<warning> session_process.go:91: Wait command kwin_no_scale [] failed: exit status 139
<info> session_process.go:104: kwin_no_scale [] startup duration: 95.470237ms
<warning> startmanager.go:92: open /usr/lib/UIAppSched.hooks/launched: no such file or directory
<warning> startmanager.go:148: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session_process.go:91: Wait command /usr/lib/deepin-daemon/dde-session-daemon [] failed: exit status 1
<info> session_process.go:104: /usr/lib/deepin-daemon/dde-session-daemon [] startup duration: 219.922595ms
<warning> session_process.go:91: Wait command /usr/bin/dde-dock [] failed: signal: segmentation fault
<info> session_process.go:104: /usr/bin/dde-dock [] startup duration: 46.247104ms
<warning> session_process.go:91: Wait command /usr/bin/dde-desktop [] failed: signal: segmentation fault
<info> session_process.go:104: /usr/bin/dde-desktop [] startup duration: 76.428057ms
<info> session_process.go:59: start dde-session-daemon part2 cost: 432.175µs
<warning> session_process.go:63: org.freedesktop.DBus.Error.NameHasNoOwner:Name "com.deepin.daemon.Daemon" does not exist
<info> main.go:125: iowait disabled

$ x11docker --sudouser --xpra --clipboard x11docker-deepin-wechat
x11docker WARNING: User werner is member of group docker.
  That allows unprivileged processes on host to gain root privileges.

x11docker note: Option --xpra: If you encounter issues with xpra, 
  you can try --nxagent instead.
  Rather use xpra from www.xpra.org than from distribution repositories.

x11docker WARNING: Option --sudouser severly reduces container security.
  Container gains additional capabilities to allow sudo and su.
  If an application breaks out of container, it can harm your system
  in many ways without you noticing. Password: x11docker

x11docker note: Option --sudouser: Enabling option --newprivileges=yes.
  You can avoid this with --newprivileges=no

x11docker WARNING: Option --newprivileges=yes: x11docker does not set 
  docker run option --security-opt=no-new-privileges. 
  That degrades container security.
  However, this is still within a default docker setup.

<warning> sound_effect.go:58: open /etc/lightdm/lightdm.conf: no such file or directory
<warning> brightness.go:154: failed to set brightness to 1 for screen: The output(61) has invalid gamma size
<warning> manager.go:619: The output(61) has invalid gamma size
<info> manager.go:630: [updateMonitors] add monitor: screen 0 0 1920 1080
<warning> config_version.go:47: Failed to delete config: remove /home/werner/.config/deepin/startdde/display.json: no such file or directory
<warning> brightness.go:154: failed to set brightness to 1 for screen: The output(61) has invalid gamma size
<warning> brightness.go:138: The output(61) has invalid gamma size
<error> xsettings.go:243: Start xsettings failed: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
  ->  main.go:98
  ->  proc.go:198
  ->  asm_amd64.s:2361
<warning> main.go:101: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session.go:293: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session.go:509: exec gnome-keyring-daemon err: fork/exec /usr/bin/gnome-keyring-daemon: operation not permitted
<warning> session_process.go:91: Wait command kwin_no_scale [] failed: exit status 1
<info> session_process.go:104: kwin_no_scale [] startup duration: 202.758427ms
<warning> startmanager.go:92: open /usr/lib/UIAppSched.hooks/launched: no such file or directory
<warning> startmanager.go:148: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session_process.go:91: Wait command /usr/lib/deepin-daemon/dde-session-daemon [] failed: exit status 1
<info> session_process.go:104: /usr/lib/deepin-daemon/dde-session-daemon [] startup duration: 72.12591ms
<info> session_process.go:104: /usr/bin/dde-dock [] startup duration: 69.960912ms
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
<info> session_process.go:104: /usr/bin/dde-desktop [] startup duration: 390.324481ms
<info> session_process.go:59: start dde-session-daemon part2 cost: 381.852µs
<warning> session_process.go:63: org.freedesktop.DBus.Error.NameHasNoOwner:Name "com.deepin.daemon.Daemon" does not exist
<info> main.go:125: iowait disabled
Gkr-Message: secret service operation failed: Failed to execute program org.freedesktop.secrets: Operation not permitted

** (process:128): WARNING **: Failed to get default keyring: 6
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x58 pc=0x613a32]

goroutine 210 [running]:
pkg.deepin.io/lib/dbus1.(*Conn).getSerial(0x0, 0xc42035e420)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/conn.go:273 +0x22
pkg.deepin.io/lib/dbus1.(*Object).createCall(0xc420206ed0, 0x7f4ffc811020, 0xc4200160c8, 0xc42023e080, 0x34, 0x0, 0xc4205301e0, 0xc420354720, 0x1, 0x1, ...)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:135 +0xf6
pkg.deepin.io/lib/dbus1.(*Object).Go(0xc420206ed0, 0xc42023e080, 0x34, 0x0, 0xc4205301e0, 0xc420354720, 0x1, 0x1, 0x34)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:115 +0xbf
pkg.deepin.io/lib/dbusutil/proxy.(*Object).Go_(0xc420206ea0, 0xc42023e080, 0x34, 0x86e100, 0xc4205301e0, 0xc420354720, 0x1, 0x1, 0xc420364201)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbusutil/proxy/object.go:57 +0x85
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).GoMarkLaunched(0xc420206ea0, 0x0, 0xc4205301e0, 0xc4201ec3c0, 0x39, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:102 +0x122
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).MarkLaunched(0xc420206ea0, 0xc4201ec300, 0xc4201ec3c0, 0x39, 0x0, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:106 +0x65
main.(*StartManager).launchAppWithOptions(0xc4203724e0, 0xc4201ec3c0, 0x39, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
    /build/startdde-3.14.7/startmanager.go:238 +0x2df
main.startAutostartProgram.func1(0xc4201ec3c0, 0x39)
    /build/startdde-3.14.7/startmanager.go:912 +0xf9
created by main.startAutostartProgram
    /build/startdde-3.14.7/startmanager.go:903 +0x77
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x58 pc=0x613a32]

goroutine 211 [running]:
pkg.deepin.io/lib/dbus1.(*Conn).getSerial(0x0, 0xc4202b2000)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/conn.go:273 +0x22
pkg.deepin.io/lib/dbus1.(*Object).createCall(0xc420206ed0, 0x7f4ffc811020, 0xc4200160c8, 0xc4202da000, 0x34, 0x0, 0xc4202e4000, 0xc4202b8000, 0x1, 0x1, ...)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:135 +0xf6
pkg.deepin.io/lib/dbus1.(*Object).Go(0xc420206ed0, 0xc4202da000, 0x34, 0x0, 0xc4202e4000, 0xc4202b8000, 0x1, 0x1, 0x34)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:115 +0xbf
pkg.deepin.io/lib/dbusutil/proxy.(*Object).Go_(0xc420206ea0, 0xc4202da000, 0x34, 0x86e100, 0xc4202e4000, 0xc4202b8000, 0x1, 0x1, 0xc42014e301)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbusutil/proxy/object.go:57 +0x85
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).GoMarkLaunched(0xc420206ea0, 0x0, 0xc4202e4000, 0xc420015110, 0x2a, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:102 +0x122
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).MarkLaunched(0xc420206ea0, 0xc420015100, 0xc420015110, 0x2a, 0x0, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:106 +0x65
main.(*StartManager).launchAppWithOptions(0xc4203724e0, 0xc420015110, 0x2a, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
    /build/startdde-3.14.7/startmanager.go:238 +0x2df
main.startAutostartProgram.func1(0xc420015110, 0x2a)
    /build/startdde-3.14.7/startmanager.go:912 +0xf9
created by main.startAutostartProgram
    /build/startdde-3.14.7/startmanager.go:903 +0x77

$ x11docker --sudouser --hostdisplay --clipboard x11docker-deepin-wechat
x11docker WARNING: User werner is member of group docker.
  That allows unprivileged processes on host to gain root privileges.

x11docker WARNING: Option --clipboard: To allow clipboard sharing with
  option --hostdisplay, trusted cookies will be enabled.
  No protection against X security leaks is left!
  Consider to use another X server option.

x11docker note: Option --hostdisplay: To allow --hostdisplay with trusted cookies,
  x11docker must share host IPC namespace with container (option --hostipc)
  to allow shared memory for X extension MIT-SHM.

x11docker WARNING: Option --hostdisplay with trusted cookies provides
      QUITE BAD CONTAINER ISOLATION !
  Keylogging and controlling host applications is possible! 
  Clipboard sharing is enabled (option --cliboard).
  It is recommended to use another X server option like --xpra or --nxagent.

x11docker note: Option --hostdisplay may fail with proprietary NVIDIA driver
  on host. In that case try other X server options like --xpra or --xephyr.

x11docker WARNING: Option --hostipc severely degrades 
  container isolation. IPC namespace remapping is disabled.

x11docker WARNING: Option --sudouser severly reduces container security.
  Container gains additional capabilities to allow sudo and su.
  If an application breaks out of container, it can harm your system
  in many ways without you noticing. Password: x11docker

x11docker note: Option --sudouser: Enabling option --newprivileges=yes.
  You can avoid this with --newprivileges=no

x11docker WARNING: Option --newprivileges=yes: x11docker does not set 
  docker run option --security-opt=no-new-privileges. 
  That degrades container security.
  However, this is still within a default docker setup.

<warning> sound_effect.go:58: open /etc/lightdm/lightdm.conf: no such file or directory
<info> manager.go:630: [updateMonitors] add monitor: HDMI-0 0 0 1920 1080
<warning> config_version.go:47: Failed to delete config: remove /home/werner/.config/deepin/startdde/display.json: no such file or directory
<error> xsettings.go:243: Start xsettings failed: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
  ->  main.go:98
  ->  proc.go:198
  ->  asm_amd64.s:2361
<warning> main.go:101: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session.go:293: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session.go:509: exec gnome-keyring-daemon err: fork/exec /usr/bin/gnome-keyring-daemon: operation not permitted
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
<warning> session_process.go:91: Wait command kwin_no_scale [] failed: exit status 1
<info> session_process.go:104: kwin_no_scale [] startup duration: 226.247124ms
<warning> startmanager.go:92: open /usr/lib/UIAppSched.hooks/launched: no such file or directory
<warning> startmanager.go:148: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session_process.go:91: Wait command /usr/lib/deepin-daemon/dde-session-daemon [] failed: exit status 1
<info> session_process.go:104: /usr/lib/deepin-daemon/dde-session-daemon [] startup duration: 79.247115ms
<info> session_process.go:104: /usr/bin/dde-dock [] startup duration: 74.406089ms
<warning> session_process.go:91: Wait command /usr/bin/dde-desktop [] failed: signal: segmentation fault
<info> session_process.go:104: /usr/bin/dde-desktop [] startup duration: 359.28289ms
<info> session_process.go:59: start dde-session-daemon part2 cost: 417.068µs
<warning> session_process.go:63: org.freedesktop.DBus.Error.NameHasNoOwner:Name "com.deepin.daemon.Daemon" does not exist
<info> main.go:125: iowait disabled
Gkr-Message: secret service operation failed: Failed to execute program org.freedesktop.secrets: Operation not permitted

** (process:128): WARNING **: Failed to get default keyring: 6
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x58 pc=0x613a32]

goroutine 167 [running]:
pkg.deepin.io/lib/dbus1.(*Conn).getSerial(0x0, 0xc4203200c0)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/conn.go:273 +0x22
pkg.deepin.io/lib/dbus1.(*Object).createCall(0xc4203564e0, 0x7f1e846b60a0, 0xc4200160a0, 0xc4202b0000, 0x34, 0x0, 0xc4201b4060, 0xc4201ee1e0, 0x1, 0x1, ...)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:135 +0xf6
pkg.deepin.io/lib/dbus1.(*Object).Go(0xc4203564e0, 0xc4202b0000, 0x34, 0x0, 0xc4201b4060, 0xc4201ee1e0, 0x1, 0x1, 0x34)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:115 +0xbf
pkg.deepin.io/lib/dbusutil/proxy.(*Object).Go_(0xc4203564b0, 0xc4202b0000, 0x34, 0x86e100, 0xc4201b4060, 0xc4201ee1e0, 0x1, 0x1, 0xc42014e101)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbusutil/proxy/object.go:57 +0x85
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).GoMarkLaunched(0xc4203564b0, 0x0, 0xc4201b4060, 0xc42034b600, 0x39, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:102 +0x122
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).MarkLaunched(0xc4203564b0, 0xc42034b600, 0xc42034b600, 0x39, 0x0, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:106 +0x65
main.(*StartManager).launchAppWithOptions(0xc42035c4e0, 0xc42034b600, 0x39, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
    /build/startdde-3.14.7/startmanager.go:238 +0x2df
main.startAutostartProgram.func1(0xc42034b600, 0x39)
    /build/startdde-3.14.7/startmanager.go:912 +0xf9
created by main.startAutostartProgram
    /build/startdde-3.14.7/startmanager.go:903 +0x77
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x58 pc=0x613a32]

goroutine 166 [running]:
pkg.deepin.io/lib/dbus1.(*Conn).getSerial(0x0, 0xc4201e6000)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/conn.go:273 +0x22
pkg.deepin.io/lib/dbus1.(*Object).createCall(0xc4203564e0, 0x7f1e846b60a0, 0xc4200160a0, 0xc42042a000, 0x34, 0x0, 0xc42012a060, 0xc42023a000, 0x1, 0x1, ...)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:135 +0xf6
pkg.deepin.io/lib/dbus1.(*Object).Go(0xc4203564e0, 0xc42042a000, 0x34, 0x0, 0xc42012a060, 0xc42023a000, 0x1, 0x1, 0x34)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:115 +0xbf
pkg.deepin.io/lib/dbusutil/proxy.(*Object).Go_(0xc4203564b0, 0xc42042a000, 0x34, 0x86e100, 0xc42012a060, 0xc42023a000, 0x1, 0x1, 0xc420258101)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbusutil/proxy/object.go:57 +0x85
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).GoMarkLaunched(0xc4203564b0, 0x0, 0xc42012a060, 0xc420362c60, 0x25, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:102 +0x122
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).MarkLaunched(0xc4203564b0, 0xc420362c00, 0xc420362c60, 0x25, 0x0, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:106 +0x65
main.(*StartManager).launchAppWithOptions(0xc42035c4e0, 0xc420362c60, 0x25, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
    /build/startdde-3.14.7/startmanager.go:238 +0x2df
main.startAutostartProgram.func1(0xc420362c60, 0x25)
    /build/startdde-3.14.7/startmanager.go:912 +0xf9
created by main.startAutostartProgram
    /build/startdde-3.14.7/startmanager.go:903 +0x77

How to solve these problems?

Regards, HY

mviereck commented 3 years ago
hongyi-zhao commented 3 years ago

Still failed, see following:

werner@X10DAi:~$ x11docker --sudouser --desktop --xephyr --clipboard x11docker-deepin-wechat
x11docker WARNING: User werner is member of group docker.
  That allows unprivileged processes on host to gain root privileges.

x11docker note: Sharing picture clips with option --clipboard
  is only possible with options --xpra, --xpra-xwayland and --hostdisplay.

x11docker note: Xephyr is a quite stable nested X server.
  Less stable, but resizeable is nxagent with option --nxagent.

x11docker note: Option --clipboard: Need either xclip or xsel
  for clipboard sharing with X server --xephyr.
  Fallback: Disabling option --clipboard.

x11docker WARNING: Option --sudouser severly reduces container security.
  Container gains additional capabilities to allow sudo and su.
  If an application breaks out of container, it can harm your system
  in many ways without you noticing. Password: x11docker

x11docker note: Option --sudouser: Enabling option --newprivileges=yes.
  You can avoid this with --newprivileges=no

x11docker WARNING: Option --newprivileges=yes: x11docker does not set 
  docker run option --security-opt=no-new-privileges. 
  That degrades container security.
  However, this is still within a default docker setup.

backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
backend_syslog.go:45: <info> syslog is not available: Unix syslog delivery error
<warning> sound_effect.go:58: open /etc/lightdm/lightdm.conf: no such file or directory
<warning> brightness.go:154: failed to set brightness to 1 for default: The output(916) has invalid gamma size
<warning> manager.go:619: The output(916) has invalid gamma size
<info> manager.go:630: [updateMonitors] add monitor: default 0 0 1824 984
<warning> config_version.go:47: Failed to delete config: remove /home/werner/.config/deepin/startdde/display.json: no such file or directory
<warning> brightness.go:154: failed to set brightness to 1 for default: The output(916) has invalid gamma size
<warning> brightness.go:138: The output(916) has invalid gamma size
<error> xsettings.go:243: Start xsettings failed: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
  ->  main.go:98
  ->  proc.go:198
  ->  asm_amd64.s:2361
<warning> main.go:101: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session.go:293: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session.go:509: exec gnome-keyring-daemon err: fork/exec /usr/bin/gnome-keyring-daemon: operation not permitted
<info> session_process.go:104: kwin_no_scale [] startup duration: 330.553783ms
<warning> startmanager.go:92: open /usr/lib/UIAppSched.hooks/launched: no such file or directory
<warning> startmanager.go:148: dial unix /var/run/dbus/system_bus_socket: connect: no such file or directory
<warning> session_process.go:91: Wait command /usr/lib/deepin-daemon/dde-session-daemon [] failed: exit status 1
<info> session_process.go:104: /usr/lib/deepin-daemon/dde-session-daemon [] startup duration: 209.26412ms
<info> session_process.go:104: /usr/bin/dde-dock [] startup duration: 70.257995ms
<info> session_process.go:104: /usr/bin/dde-desktop [] startup duration: 635.904719ms
<info> session_process.go:59: start dde-session-daemon part2 cost: 597.41µs
<warning> session_process.go:63: org.freedesktop.DBus.Error.NameHasNoOwner:Name "com.deepin.daemon.Daemon" does not exist
<info> main.go:125: iowait disabled
Gkr-Message: secret service operation failed: Failed to execute program org.freedesktop.secrets: Operation not permitted

** (process:128): WARNING **: Failed to get default keyring: 6
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x58 pc=0x613a32]

goroutine 166 [running]:
pkg.deepin.io/lib/dbus1.(*Conn).getSerial(0x0, 0xc42014af60)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/conn.go:273 +0x22
pkg.deepin.io/lib/dbus1.(*Object).createCall(0xc4201de5d0, 0x7f7a74114020, 0xc4200160a0, 0xc4201e6080, 0x34, 0x0, 0xc42057e1e0, 0xc420011640, 0x1, 0x1, ...)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:135 +0xf6
pkg.deepin.io/lib/dbus1.(*Object).Go(0xc4201de5d0, 0xc4201e6080, 0x34, 0x0, 0xc42057e1e0, 0xc420011640, 0x1, 0x1, 0x34)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbus1/object.go:115 +0xbf
pkg.deepin.io/lib/dbusutil/proxy.(*Object).Go_(0xc4201de5a0, 0xc4201e6080, 0x34, 0x86e100, 0xc42057e1e0, 0xc420011640, 0x1, 0x1, 0xc42014e301)
    /usr/share/gocode/src/pkg.deepin.io/lib/dbusutil/proxy/object.go:57 +0x85
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).GoMarkLaunched(0xc4201de5a0, 0x0, 0xc42057e1e0, 0xc42024e980, 0x39, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:102 +0x122
github.com/linuxdeepin/go-dbus-factory/com%2edeepin%2edaemon%2eapps.(*launchedRecorder).MarkLaunched(0xc4201de5a0, 0xc42024e900, 0xc42024e980, 0x39, 0x0, 0x0)
    /usr/share/gocode/src/github.com/linuxdeepin/go-dbus-factory/com.deepin.daemon.apps/auto.go:106 +0x65
main.(*StartManager).launchAppWithOptions(0xc4201dc270, 0xc42024e980, 0x39, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
    /build/startdde-3.14.7/startmanager.go:238 +0x2df
main.startAutostartProgram.func1(0xc42024e980, 0x39)
    /build/startdde-3.14.7/startmanager.go:912 +0xf9
created by main.startAutostartProgram
    /build/startdde-3.14.7/startmanager.go:903 +0x77
werner@X10DAi:~$ 
hongyi-zhao commented 3 years ago

OTOH, even I can start the deepin-terminal with the following command:

$ x11docker --sudouser --clipboard x11docker-deepin-wechat deepin-terminal

But when I try to install package(s) in the opened dockerized terminal, I meet the error as shown below:

werner@bcd5b388f5b1:~$ sudo apt-get install easyconnect
Reading package lists... Done
Building dependency tree       
Reading state information... Done
easyconnect is already the newest version (7.6.3.0.86415).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
werner@bcd5b388f5b1:~$ sudo apt-get install --reinstall easyconnect
Reading package lists... Done
Building dependency tree       
Reading state information... Done
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 0 not upgraded.
Need to get 0 B/59.1 MB of archives.
After this operation, 0 B of additional disk space will be used.
(Reading database ... 128239 files and directories currently installed.)
Preparing to unpack .../easyconnect_7.6.3.0.86415_amd64.deb ...
Unknown operation staop.
Removed /etc/systemd/system/multi-user.target.wants/EasyMonitor.service.
rm pkg before...
preinst
Linux bcd5b388f5b1 5.4.0-52-generic #57-Ubuntu SMP Thu Oct 15 10:57:00 UTC 2020 x86_64 GNU/Linux
Unpacking easyconnect (7.6.3.0.86415) over (7.6.3.0.86415) ...
upgrade...
after rm pkt ...
Processing triggers for lastore-daemon (0.14.6-1+comsta) ...
Processing triggers for mime-support (3.60) ...
Processing triggers for desktop-file-utils (0.23-1) ...
Processing triggers for bamfdaemon (0.5.3-2) ...
Rebuilding /usr/share/applications/bamf-2.index...
Setting up easyconnect (7.6.3.0.86415) ...
Created symlink /etc/systemd/system/multi-user.target.wants/EasyMonitor.service → /lib/systemd/system/EasyMonitor.service.
Failed to connect to bus: No such file or directory
after install pkg ...

N.B. At this moment, I've revised the Dockerfile into the following and re-created the image:

FROM x11docker/deepin
RUN echo "deb http://packages.deepin.com/deepin/ lion main non-free contrib" > /etc/apt/sources.list
RUN env DEBIAN_FRONTEND=noninteractive dpkg --add-architecture i386 && apt-get update
RUN env DEBIAN_FRONTEND=noninteractive apt-get install -y \
    lsb-release apt-utils deepin-wine deepin-wine32 deepin-wine32-preloader deepin-wine-helper deepin-wine-uninstaller
RUN env DEBIAN_FRONTEND=noninteractive apt-get install -y deepin.com.wechat
mviereck commented 3 years ago

Start the deepin desktop with needed options as described in README.md.

But when I try to install package(s) in the opened dockerized terminal, I meet the error as shown below:

Which error?

hongyi-zhao commented 3 years ago

Start the deepin desktop with needed options as described in README.md.

Tried with the following:

$ x11docker --desktop --init=systemd -- --cap-add=IPC_LOCK --security-opt seccomp=unconfined -- x11docker-deepin-wechat

But only get a near whole white login UI without QR code as shown below.

image

But when I try to install package(s) in the opened dockerized terminal, I meet the error as shown below:

Which error?

werner@bcd5b388f5b1:~$ sudo apt-get install --reinstall easyconnect
Reading package lists... Done
Building dependency tree       
Reading state information... Done
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 0 not upgraded.
Need to get 0 B/59.1 MB of archives.
After this operation, 0 B of additional disk space will be used.
(Reading database ... 128239 files and directories currently installed.)
Preparing to unpack .../easyconnect_7.6.3.0.86415_amd64.deb ...
Unknown operation staop.
Removed /etc/systemd/system/multi-user.target.wants/EasyMonitor.service.
rm pkg before...
preinst
Linux bcd5b388f5b1 5.4.0-52-generic #57-Ubuntu SMP Thu Oct 15 10:57:00 UTC 2020 x86_64 GNU/Linux
Unpacking easyconnect (7.6.3.0.86415) over (7.6.3.0.86415) ...
upgrade...
after rm pkt ...
Processing triggers for lastore-daemon (0.14.6-1+comsta) ...
Processing triggers for mime-support (3.60) ...
Processing triggers for desktop-file-utils (0.23-1) ...
Processing triggers for bamfdaemon (0.5.3-2) ...
Rebuilding /usr/share/applications/bamf-2.index...
Setting up easyconnect (7.6.3.0.86415) ...
Created symlink /etc/systemd/system/multi-user.target.wants/EasyMonitor.service → /lib/systemd/system/EasyMonitor.service.
Failed to connect to bus: No such file or directory
[...]

I mean this one.

mviereck commented 3 years ago
Failed to connect to bus: No such file or directory

The installer failed to connect to dbus. It is normal case that no dbus daemon runs during installation. That is harmless.

But only get a near whole white login UI without QR code as shown below.

Here it takes a long time until window and QR code appear. Maybe you have just to wait. Also check if you have a working internet connection in the container.

hongyi-zhao commented 3 years ago

Here it takes a long time until window and QR code appear. Maybe you have just to wait. Also check if you have a working internet connection in the container.

Got it. The following command will flush the IP address on docker0 interface as we have discussed before:

$ x11docker --desktop --init=systemd -- --cap-add=IPC_LOCK --security-opt seccomp=unconfined -- x11docker-deepin-wechat

And the following command will do the trick:

$ x11docker --desktop --init=systemd --hostnet -- --cap-add=IPC_LOCK --security-opt seccomp=unconfined -- x11docker-deepin-wechat

See the following screenshot for the result I've achieved till now:

image

Thank you very much again for your warm help and detailed explanations.

Another question: Why you use two '--'s in the above command like that?

Regards, HY

mviereck commented 3 years ago

Compare the syntax explained in x11docker --help:

Usage:
To run a Docker container on a new X server:
  x11docker IMAGE
  x11docker [OPTIONS] IMAGE [COMMAND]
  x11docker [OPTIONS] -- IMAGE [COMMAND [ARG1 ARG2 ...]]
  x11docker [OPTIONS] -- DOCKER_RUN_OPTIONS -- IMAGE [COMMAND [ARG1 ARG2 ...]]

Custom docker run options are encapsulated in two --.

hongyi-zhao commented 3 years ago

Wonderful. Anyway, docker/x11docker are complicated and powerful tools. Thanks again for your hard work and contributions to open source community again.

HY