add dockerfile and readme

This commit is contained in:
Simon Vieille 2022-08-30 10:18:29 +02:00
commit e939e93f65
Signed by: deblan
GPG Key ID: 579388D585F70417
2 changed files with 29 additions and 0 deletions

13
Dockerfile Normal file
View File

@ -0,0 +1,13 @@
FROM ubuntu:22.04
RUN apt-get update && apt-get install -y curl
RUN curl -fsSL https://deb.nodesource.com/setup_16.x | bash - && apt-get install -y nodejs
RUN npm install -g playwright && npx playwright install-deps
RUN useradd -d /home/nodejs -m -s /usr/bin/bash -p `openssl rand -hex 32` nodejs
RUN mkdir /app && chown nodejs:nodejs /app
USER nodejs
RUN npx playwright install
WORKDIR /app
CMD ["node"]

16
README.md Normal file
View File

@ -0,0 +1,16 @@
# deblan/playwright
Docker image to run [playwright](https://github.com/microsoft/playwright).
## Installation
```
docker pull deblan/playwright
```
## Usage
```
cd /path/to/project
docker run docker run -it -v $(pwd):/app --rm deblan/playwright npx playwright test
```