chore: add Python to docker images (#5139)

This adds +100MB to network transfer size but enables our
users to use playwright-python from-inside docker container.
This commit is contained in:
Andrey Lushnikov 2021-01-27 08:51:51 -08:00 committed by GitHub
parent 90bc837e55
commit 9de0a5a963
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 0 deletions

View file

@ -68,6 +68,12 @@ RUN apt-get update && apt-get install -y --no-install-recommends git ssh && \
# Create the pwuser (we internally create a symlink for the pwuser and the root user)
RUN adduser pwuser
# Install Python 3.8
RUN apt-get update && apt-get install -y python3.8 python3-pip && \
update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 1 && \
update-alternatives --install /usr/bin/python python /usr/bin/python3 1
# === BAKE BROWSERS INTO IMAGE ===
# 1. Add tip-of-tree Playwright package to install its browsers.

View file

@ -67,6 +67,12 @@ RUN apt-get update && apt-get install -y --no-install-recommends git ssh && \
# Create the pwuser (we internally create a symlink for the pwuser and the root user)
RUN adduser pwuser
# Install Python 3.8
RUN apt-get update && apt-get install -y python3.8 python3-pip && \
update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 1 && \
update-alternatives --install /usr/bin/python python /usr/bin/python3 1
# === BAKE BROWSERS INTO IMAGE ===
# 1. Add tip-of-tree Playwright package to install its browsers.