-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Closed as not planned
Closed as not planned
Copy link
Labels
CIGeneral issues involving running in a CI providerGeneral issues involving running in a CI providerstaleno activity on this issue for a long periodno activity on this issue for a long period
Description
I decided to put my tests into a docker container, but I started facing an issue.
When I tried to map my current dir to a folder inside my container, I started getting this error: Could not find a Cypress configuration file, exiting. We looked but did not find a cypress.json file in this folder: /usr/src/app
Here's my Dockerfile:
# pull official Cypress image
FROM cypress/included:5.5.0
# set working directory
RUN mkdir /usr/src/app
WORKDIR /usr/src/app
# copy our test application
COPY package.json /usr/src/app/package.json
COPY package-lock.json /usr/src/app/package-lock.json
# install NPM dependencies and Cypress binary
RUN npm ci
# copy all files into the container
COPY . /usr/src/app
COPY cypress.json /usr/src/app/cypress.json
# check if the binary was installed successfully
RUN $(npm bin)/cypress verify
# run tests
CMD ["./node_modules/.bin/cypress", "run"]Here's my command
docker run -v $PWD:/usr/src/app --ipc=host image:latest --headless --browser chrome
And like usually it works on my local, but doesn't work on Jenkins. I'm not sure what I'm missing. I was using this article as the reference. Just for the record, I tried to pass -w /usr/src/app flag as well.
canbax, arjunu, hadrien-toma, riccardomarotti and denbon05
Metadata
Metadata
Assignees
Labels
CIGeneral issues involving running in a CI providerGeneral issues involving running in a CI providerstaleno activity on this issue for a long periodno activity on this issue for a long period