1 | version: '2'
|
2 |
|
3 | services:
|
4 | test:
|
5 | image: crystal-ball/webpack-base
|
6 | expose:
|
7 | - 5000
|
8 |
|
9 | cypress:
|
10 | build:
|
11 | context: .
|
12 | dockerfile: ./cypress/Dockerfile
|
13 | # See https://github.com/cypress-io/cypress/issues/350
|
14 | ipc: host
|
15 | environment:
|
16 | ## This ensures colors are enabled in the output
|
17 | - TERM=xterm
|
18 | # Cypress env overrides for CI/CD
|
19 | - CYPRESS_baseUrl=http://test:5000
|
20 | # Pass through env variables and tokens from ci-cd workflow for
|
21 | # Cypress+Percy to determine test run git info
|
22 | - PERCY_BRANCH=${PERCY_BRANCH}
|
23 | - PERCY_TOKEN=${PERCY_TOKEN}
|
24 | depends_on:
|
25 | - test
|
26 | # Share the current folder as volume to avoid copying
|
27 | working_dir: /e2e
|
28 | volumes:
|
29 | - ./:/e2e
|