Skip to content

Instantly share code, notes, and snippets.

@demaniak
Created April 24, 2020 06:55
Show Gist options
  • Star 9 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save demaniak/c56531c8d673a6f58ee54b5621796548 to your computer and use it in GitHub Desktop.
Save demaniak/c56531c8d673a6f58ee54b5621796548 to your computer and use it in GitHub Desktop.
Run Microsoft teams in docker on linux
#!/bin/bash
FILE=teams.deb
if [ ! -f "$FILE" ]; then
curl -L -o $FILE "https://go.microsoft.com/fwlink/p/?linkid=2112886&clcid=0x1c09&culture=en-za&country=za"
fi
docker build -t ms-teams-docker .
FROM ubuntu
RUN apt-get update && \
apt-get install -y curl apt-utils \
libasound2 libatk-bridge2.0-0 libcairo2 libcups2 libgdk-pixbuf2.0-0 \
libgtk-3-0 libnspr4 libnss3 libpango-1.0-0 libpangocairo-1.0-0 \
libsecret-1-0 libx11-xcb1 libxcomposite1 libxcomposite1 \
libxss1 apt-transport-https libxkbfile1
COPY teams.deb /tmp/teams.deb
RUN dpkg -i /tmp/teams.deb && apt-get install -f
#!/bin/bash
docker run -it --net=host --env="DISPLAY" \
--volume="$HOME/.Xauthority:/root/.Xauthority:rw" \
--privileged \
ms-teams-docker
@Diadochokinetic
Copy link

Hello,

I just can't start teams. After running the run.sh a command line opens as intended. Unfortunately nothing happens when I try to launch teams. Any chance somebody has an idea what could cause the issue?

@k-popov
Copy link

k-popov commented Sep 21, 2020

Also makes sense to use a non-root user as the container itself is privileged:

RUN useradd teams && mkdir -p /home/teams && chown teams:teams /home/teams
USER teams

And with --volume="$HOME/.Xauthority:/home/teams/.Xauthority:rw" of course.

@olberger
Copy link

I've reused some its of this gist to embed everything in a fork of https://github.com/mdouchement/docker-zoom-us, which I have committed to https://github.com/olberger/docker-teams-linux

No warranty, as I haven't tested much.

Hope this works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment