hi 🙂
i just set up prisma, graphql-yoga and postgresql with docker. Also got the postdeploy hooks running, where after deploying the prisma service, the prisma.graphql schema will be refetched and the typescript prisma-client will be regenerated.
Now here is my problem (in my personal & my official project with my teammate): GraphQL-yoga imports the schema.graphql, which indeed uses types and inputs from the generated prisma.graphql file, which can only be generated from a running prisma instance with a deployed prisma service. This is fine if you still have an 'old' prisma.graphql file, however deploying the prisma service will only update the generated files on the local computer and not in the docker container.
Is there any way to also update the generated files in the docker container without having to install the prisma cli on docker and trigger things from there (we're also looking for a CI/CD solution for our second project)?
My first idea would be something like: start docker container (already old prisma.graphql in the project) -> prisma deploy -> get-schema from endpoint -> prisma generate (the typescript prisma-client) -> COPY over the 'generated' folder