Skip to content

Commit

Permalink
Merge branch 'braking-change-update-prisma-client' into beta
Browse files Browse the repository at this point in the history
  • Loading branch information
aiji42 committed Jul 4, 2022
2 parents 54ec0da + b5a7464 commit 8fc3d0b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ services:
entrypoint: /app/entrypoint.sh
command: yarn pdp
environment:
PRISMA_SCHEMA_PATH=/app/path/your/schema.prisma
PRISMA_SCHEMA_PATH: /app/for/your/schema.prisma
DATABASE_URL: your DATABASE_URL
DATA_PROXY_API_KEY: your DATA_PROXY_API_KEY
PORT: "3000"
Expand Down Expand Up @@ -140,6 +140,8 @@ FROM base
COPY --from=builder /app/node_modules ./node_modules
COPY --from=builder /app/package.json ./package.json

ENV PRISMA_SCHEMA_PATH=/app/node_modules/.prisma/client/schema.prisma

USER node

ENTRYPOINT ["/usr/bin/tini", "--"]
Expand Down
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ services:
entrypoint: /app/entrypoint.sh
command: ./wait-for-it.sh https-portal3000:443 --timeout=120 --strict -- yarn dev:server
environment:
PRISMA_SCHEMA_PATH: /app/node_modules/.prisma/client/schema.prisma
DATABASE_URL: postgresql://postgres:pass@db:5432/postgres?schema=public
DATA_PROXY_API_KEY: custometoken
MIGRATE: "true"
Expand Down
2 changes: 1 addition & 1 deletion src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ app.use(afterMiddleware());

(async () => {
const dmmf = await getDMMF({
datamodel: getSchemaSync(),
datamodel: getSchemaSync(process.env.PRISMA_SCHEMA_PATH),
});
const server = new ApolloServer({
...makeServerConfig(dmmf, db),
Expand Down

0 comments on commit 8fc3d0b

Please sign in to comment.