Im running this dockerfile and I get: ERROR Run python -m playwright install
/bin/sh python: not found
FROM mcr.microsoft.com/playwright:focal
RUN apt-get update && apt-get install -y python3-pip
COPY . .
RUN pip3 install TikTokApi
RUN python -m playwright install // Results in error
2
Answers
If you want a Playwright image with Python instead of the Playwright image with Node you have currently set,
do
instead. You won’t then need to install
python3-pip
(or playwright!) at all.Additionally, you’ll probably want to explicitly spell out
python3
instead ofpython
:In the terminal of vscode, type
sudo apt install python-is-python3
then restart, it should work.