Nexus-plugin-prisma: Blog example: Error messages on production env

Created on 31 Oct 2019  路  1Comment  路  Source: graphql-nexus/nexus-plugin-prisma

I setup your blog example using Prisma 2: https://github.com/prisma-labs/nexus-prisma/tree/master/examples/blog

I created the following Dockerfile for prod usage:

FROM node:10 as init
COPY rootfs /
WORKDIR /app

FROM init as prod
WORKDIR /build
COPY . .
RUN /entrypoint.sh
RUN yarn build
CMD node dist/main.js

This is working, but I have some unexpected alerts:

graphql_1  | GraphQL Nexus Typegen: Expected module /build/dist/context.js to be an absolute path to a TypeScript module, skipping.
graphql_1  | 馃殌 Server ready at http://localhost:4000
graphql_1  | Missing required typegen import: Context

Am I not sure it's the normal behavior.

Most helpful comment

Hi,
Set the NODE_ENV var to "production" to get rid of this error.

>All comments

Hi,
Set the NODE_ENV var to "production" to get rid of this error.

Was this page helpful?
0 / 5 - 0 ratings