use separate dockerfiles for each container
This commit is contained in:
parent
47e5919893
commit
59da569c96
|
@ -17,3 +17,9 @@ WORKDIR /app
|
||||||
COPY --from=build /usr/src/next /app
|
COPY --from=build /usr/src/next /app
|
||||||
CMD ["pnpm", "run", "dev"]
|
CMD ["pnpm", "run", "dev"]
|
||||||
|
|
||||||
|
FROM base AS prod
|
||||||
|
WORKDIR /app
|
||||||
|
COPY --from=build /usr/src/next /app
|
||||||
|
COPY ./packages/next/app.json /app
|
||||||
|
ENTRYPOINT ["pnpm"]
|
||||||
|
CMD ["start"]
|
|
@ -54,7 +54,7 @@ services:
|
||||||
image: fp-strapi:14
|
image: fp-strapi:14
|
||||||
build:
|
build:
|
||||||
context: ./packages/strapi
|
context: ./packages/strapi
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile.strapi
|
||||||
restart: on-failure
|
restart: on-failure
|
||||||
depends_on:
|
depends_on:
|
||||||
- db
|
- db
|
||||||
|
@ -110,7 +110,7 @@ services:
|
||||||
container_name: fp-next
|
container_name: fp-next
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile.next
|
||||||
target: dev
|
target: dev
|
||||||
restart: on-failure
|
restart: on-failure
|
||||||
environment:
|
environment:
|
||||||
|
|
Loading…
Reference in New Issue