[ Prisma Client ] - Binary Targets
# orm-help
e
[ Prisma Client ] - Binary Targets
1
Hey everyone! I'm working in an enterprise project with the
prisma client 4.0.0
and a teammate uses an Apple Silicon M1 PRO processor. He can't run
npx prisma generate
because we can't specify the correct
binary target
for the M1 architecture. Does anyone know what we can do?
a
Hey Eric! It should be possible to generate the Prisma Client on an M1 without explicitly setting the binary target. Is your teammate getting a specific error message?
e
Hey, @Austin! The message didn't specify the
binary target
. I noticed that when he tried to run
npx prisma generate
while sharing the screen. I'm waiting for his reply to share here.
Hey @Austin! I still haven't received his reply. Anyway, just to bring more visibility about the problem, I think we will need to explicitly set the
binary target
because we're using another architecture to run the application with
Docker
. In addition, we've bound the
node_modules
folder with
Docker Compose
and, consequently, we've bound the
Prisma Client
.
a
What binary targets do you have specified now? I use an M1 so I will try to reproduce the issue.
e
We've specified these binary targets:
["native", "darwin", "debian-openssl-1.1.x", "linux-musl"]
When I was with him on call, I saw a message to use the binary target
linux-arm64-undefined
on terminal.
We're using an Docker image from
node:16.15.1-alpine3.14
a
That helps! Was he running
prisma generate
in the container or on his local machine?
e
On his local machine
a
I have no trouble running Prisma generate on my Mac with those binary targets. I think the best move would be to file a bug report with all of the relevant environment information.
e
Right. When he answers, I will send a screenshot of the error message through here from my teammate's terminal before filing the bug report. Thank you so much, @Austin!
a
No problem, best of luck!
e
@Austin, I was reviewing the docker files and I just realized now that we have a
.sh
file which is running as entrypoint that contains the
npx prisma generate
This should only run from outside the container. Right?
a
It most likely depends on your specific setup. I would include all relevant Docker information in the bug report when you file.
e
Absolutely. Thank you, @Austin!
🙌 1