Unable to run Teamviewer 15 inside a Docker container

I ran into a issue when I’m not able to run Teamviewer (GUI) inside a container. Does anyone experienced this issue and have some solution? Or maybe know how to fix it? I was able to use Teamviewer outside of docker container without any issue. Any help is highly appreciated.

Dockerfile:

> FROM ubuntu:18.04
> 
> RUN apt-get update \
>     && apt-get upgrade --yes \
>     && apt-get install --yes wget \
>     && wget https://download.teamviewer.com/download/linux/teamviewer_amd64.deb \
>     && apt install --yes ./teamviewer_amd64.deb
>     && rm teamviewer_amd64.deb \
>     && apt-get clean \
>     && rm -rf /var/cache/* \
>     && rm -rf /var/lib/apt/lists/*
> 
> CMD ["teamviewer"]

Run Teamviewer:

 john@Work:~$ xhost local:root
 non-network local connections being added to access control list

    john@Work:~$ docker run \
    >     --rm \
    >     -it \
    >     --name teamviewer \
    >     --volume /tmp/.X11-unix:/tmp/.X11-unix \
    >     --env DISPLAY=:0 \
    >     teamviewer

Init...
CheckCPU: SSE2 support: yes
Checking setup...
Launching TeamViewer ...
Starting network process (no daemon)
Network process started (44)
Launching TeamViewer GUI 

After running it, teamviewer window and icon shows up for a few sec but disappears few sec later with following error:

Aborted (core dumped)

The window that shows up is not properly graphically displayed though.

Teamviewer logfile:

Starting teamviewerd…::::::::::::::::::::…
Warning: The postinst maintainerscript of the package teamviewer
Warning: seems to use apt-key (provided by apt) without depending on gnupg or gnupg2.
Warning: This will BREAK in the future and should be fixed by the package maintainer(s).
Note: Check first if apt-key functionality is needed at all - it probably isn’t!
E: gnupg, gnupg2 and gnupg1 do not seem to be installed, but one of them is required for this operation

I tried to install gnupg, gnupg2 and gnupg1 but with no luck.

I don’t know about that error, but I found this repo, with a Dockerfile thats worked fine on my Fedora.
This may help you

Unfortunately I need version 15. What you posted is old version 11.
Thanks though :slight_smile: