docs(ci): add sample config for jenkins (#3398)
This commit is contained in:
parent
962ddc09c4
commit
be7db4d2c6
20
docs/ci.md
20
docs/ci.md
|
|
@ -11,6 +11,7 @@ configurations for common CI providers.
|
||||||
* [Azure Pipelines](#azure-pipelines)
|
* [Azure Pipelines](#azure-pipelines)
|
||||||
* [Travis CI](#travis-ci)
|
* [Travis CI](#travis-ci)
|
||||||
* [CircleCI](#circleci)
|
* [CircleCI](#circleci)
|
||||||
|
* [Jenkins](#jenkins)
|
||||||
* [Bitbucket Pipelines](#bitbucket-pipelines)
|
* [Bitbucket Pipelines](#bitbucket-pipelines)
|
||||||
* [GitLab CI](#gitlab-ci)
|
* [GitLab CI](#gitlab-ci)
|
||||||
- [Caching browsers](#caching-browsers)
|
- [Caching browsers](#caching-browsers)
|
||||||
|
|
@ -170,6 +171,25 @@ We run our tests on CircleCI, with our [pre-built Docker image](docker/README.md
|
||||||
|
|
||||||
This is likely caused by Jest autodetecting the number of processes on the entire machine (`36`) rather than the number allowed to your container (`2`). To fix this, set `jest --maxWorkers=2` in your test command.
|
This is likely caused by Jest autodetecting the number of processes on the entire machine (`36`) rather than the number allowed to your container (`2`). To fix this, set `jest --maxWorkers=2` in your test command.
|
||||||
|
|
||||||
|
### Jenkins
|
||||||
|
|
||||||
|
Jenkins supports Docker agents for pipelines. Use the [Playwright Docker image](docker/README.md)
|
||||||
|
to run tests on Jenkins.
|
||||||
|
|
||||||
|
```groovy
|
||||||
|
pipeline {
|
||||||
|
agent { docker { image 'mcr.microsoft.com/playwright:bionic' } }
|
||||||
|
stages {
|
||||||
|
stage('e2e-tests') {
|
||||||
|
steps {
|
||||||
|
sh 'npm install'
|
||||||
|
sh 'npm run test'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
### Bitbucket Pipelines
|
### Bitbucket Pipelines
|
||||||
|
|
||||||
Bitbucket Pipelines can use public [Docker images as build environments](https://confluence.atlassian.com/bitbucket/use-docker-images-as-build-environments-792298897.html). To run Playwright tests on Bitbucket, use our public Docker image ([see Dockerfile](docker/README.md)).
|
Bitbucket Pipelines can use public [Docker images as build environments](https://confluence.atlassian.com/bitbucket/use-docker-images-as-build-environments-792298897.html). To run Playwright tests on Bitbucket, use our public Docker image ([see Dockerfile](docker/README.md)).
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue