mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
chore(docker): skip "recommended" dependencies (#2917)
This commit is contained in:
parent
bce4b1aea9
commit
1cebf8757c
@ -15,42 +15,44 @@ RUN apt-get update && apt-get install -y curl && \
|
|||||||
apt-get install -y nodejs
|
apt-get install -y nodejs
|
||||||
|
|
||||||
# 2. Install WebKit dependencies
|
# 2. Install WebKit dependencies
|
||||||
RUN apt-get update && apt-get install -y libwoff1 \
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||||
libopus0 \
|
libwoff1 \
|
||||||
libwebp6 \
|
libopus0 \
|
||||||
libwebpdemux2 \
|
libwebp6 \
|
||||||
libenchant1c2a \
|
libwebpdemux2 \
|
||||||
libgudev-1.0-0 \
|
libenchant1c2a \
|
||||||
libsecret-1-0 \
|
libgudev-1.0-0 \
|
||||||
libhyphen0 \
|
libsecret-1-0 \
|
||||||
libgdk-pixbuf2.0-0 \
|
libhyphen0 \
|
||||||
libegl1 \
|
libgdk-pixbuf2.0-0 \
|
||||||
libnotify4 \
|
libegl1 \
|
||||||
libxslt1.1 \
|
libnotify4 \
|
||||||
libevent-2.1-6 \
|
libxslt1.1 \
|
||||||
libgles2 \
|
libevent-2.1-6 \
|
||||||
libvpx5
|
libgles2 \
|
||||||
|
libvpx5
|
||||||
|
|
||||||
# 3. Install gstreamer and plugins to support video playback in WebKit.
|
# 3. Install gstreamer and plugins to support video playback in WebKit.
|
||||||
RUN apt-get update && apt-get install -y libgstreamer-gl1.0-0 \
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||||
libgstreamer-plugins-bad1.0-0 \
|
libgstreamer-gl1.0-0 \
|
||||||
gstreamer1.0-plugins-good
|
libgstreamer-plugins-bad1.0-0 \
|
||||||
|
gstreamer1.0-plugins-good
|
||||||
|
|
||||||
# 4. Install Chromium dependencies
|
# 4. Install Chromium dependencies
|
||||||
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||||
RUN apt-get update && apt-get install -y libnss3 \
|
libnss3 \
|
||||||
libxss1 \
|
libxss1 \
|
||||||
libasound2 \
|
libasound2 \
|
||||||
fonts-noto-color-emoji
|
fonts-noto-color-emoji
|
||||||
|
|
||||||
# 5. Install Firefox dependencies
|
# 5. Install Firefox dependencies
|
||||||
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||||
RUN apt-get update && apt-get install -y libdbus-glib-1-2 \
|
libdbus-glib-1-2 \
|
||||||
libxt6
|
libxt6
|
||||||
|
|
||||||
# 6. Install ffmpeg to bring in audio and video codecs necessary for playing videos in Firefox.
|
# 6. Install ffmpeg to bring in audio and video codecs necessary for playing videos in Firefox.
|
||||||
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||||
RUN apt-get update && apt-get install -y ffmpeg
|
ffmpeg
|
||||||
|
|
||||||
# 7. Add user so we don't need --no-sandbox in Chromium
|
# 7. Add user so we don't need --no-sandbox in Chromium
|
||||||
RUN groupadd -r pwuser && useradd -r -g pwuser -G audio,video pwuser \
|
RUN groupadd -r pwuser && useradd -r -g pwuser -G audio,video pwuser \
|
||||||
@ -58,7 +60,8 @@ RUN groupadd -r pwuser && useradd -r -g pwuser -G audio,video pwuser \
|
|||||||
&& chown -R pwuser:pwuser /home/pwuser
|
&& chown -R pwuser:pwuser /home/pwuser
|
||||||
|
|
||||||
# 8. (Optional) Install XVFB if there's a need to run browsers in headful mode
|
# 8. (Optional) Install XVFB if there's a need to run browsers in headful mode
|
||||||
RUN apt-get update && apt-get install -y xvfb
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||||
|
xvfb
|
||||||
|
|
||||||
# Run everything after as non-privileged user.
|
# 9. Run everything after as non-privileged user.
|
||||||
USER pwuser
|
USER pwuser
|
||||||
|
Loading…
x
Reference in New Issue
Block a user