when starting docker-compose an error occurs - ERROR [frontend 4/7] COPY package-lock.json ./ #9606
Unanswered
MikhailPermiakov
asked this question in
Help
Replies: 1 comment
-
|
this configuration runs without errors `apps/frontend/Dockerfile FROM node:22 but when adding data to html, the changes are not displayed on the screen |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
use docker compose
https://turbo.build/repo/docs/guides/tools/docker
does not see: package.json and package-lock.json
`docker-compose.yaml
services:
frontend:
build:
context: ./apps/frontend
ports: "3002:3002"
command: ["npm", "run", "dev"]
apps/frontend/Dockerfile
FROM node:22
WORKDIR /app
COPY package.json ./
COPY package-lock.json ./
COPY apps/frontend/package.json ./apps/frontend/package.json
RUN npm install
COPY . .
CMD ["npm", "run", "dev"]
reult - error:
=> ERROR [frontend 4/7] COPY package-lock.json ./ 0.0s
=> ERROR [frontend 5/7] COPY apps/frontend/package.json ./apps/frontend/package.json 0.0s
=> [crm 3/4] COPY . . 0.0s
[frontend 4/7] COPY package-lock.json ./:
[frontend 5/7] COPY apps/frontend/package.json ./apps/frontend/package.json:
failed to solve: failed to compute cache key: failed to calculate checksum of ref 100f2af3-40ee-4ee0-9fac-4e292818a360::ugyw4qwu01lnxr7k8hepd4t27: "/apps/frontend/package.json": not found`
Beta Was this translation helpful? Give feedback.
All reactions