Replies: 1 comment 1 reply
-
I'm trying to get this to work as well. It works just fine locally on my M1 mac but Lambda keeps throwing errors: Dockerfile # Dockerfile
# Install dependencies only when needed
FROM --platform=linux/arm64 cypress/included:10.3.1-typescript AS deps
WORKDIR /app
COPY package.json yarn.lock ./
RUN yarn install --frozen-lockfile
# Rebuild the source code only when needed
FROM --platform=linux/arm64 cypress/included:10.3.1-typescript AS builder
COPY --from=deps /root/.cache/Cypress /root/.cache/Cypress
WORKDIR /app
COPY --from=deps /app/node_modules ./node_modules
COPY . .
ENV CI=1
ENTRYPOINT ["yarn", "test:headless"] Lambda error:
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
AWS has recently announced the ability to run Docker containers in Lambda. This is very exciting, as opens the possibility of running Cypress on lambda in a less hacky, easier way.
I've been playing with this over the last day or so, and have got pretty close. I've started with one of the pre-built Cypress docker images, added the AWS NodeJs Runtime Client, however, when trying to test it, I get the following logs:
I think the main problem is that Electron (or Chrome) is trying to use
/dev/shm
, however, it doesn't seem to exist when running via Lambda. (as per this comment and this discussionWhen running
ls -l /dev
, I don't see/dev/shm
:And when calling
df -h
(to get the mounted drives), I get the following:Another error is the following, which could be fixed using this method - I'll need to investigate this tomorrow.
I've attempted to run using the following environment variables:
Is anyone else attempting/working with/playing with getting cypress to work on Lambda Containers?
Beta Was this translation helpful? Give feedback.
All reactions