Skip to content

Instantly share code, notes, and snippets.

@YusukeIwaki
Created August 31, 2021 06:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save YusukeIwaki/2117277f4cfc600073c66ead79de593f to your computer and use it in GitHub Desktop.
Save YusukeIwaki/2117277f4cfc600073c66ead79de593f to your computer and use it in GitHub Desktop.
Playwright Browser server
FROM mcr.microsoft.com/playwright:v1.14.1
RUN mkdir /playwright
WORKDIR /playwright
RUN npm install playwright@1.14.1
RUN echo '{ "port": 8080 }' > config.json
EXPOSE 8080
CMD ./node_modules/.bin/playwright launch-server chromium config.json
@YusukeIwaki
Copy link
Author

YusukeIwaki commented Aug 31, 2021

$ docker build . -t playwright114
$ docker run -p 8080:8080 --rm -it playwright114
ws://127.0.0.1:8080/a03946008b4ab43c931d15da046b8e48

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