I am trying to run a database script in my docker ...
# orm-help
d
I am trying to run a database script in my docker env but I get an error that the
env variable
cannot be found. this is the folder structure on the docker
Copy code
.env
dist
  /scripts
    script.js
node_modules
prisma
  /migrations
  schema.prisma
  seed.ts
the script files that I am running is
script.js
>
node scripts.js <arg>
it is available in the
.env
tho
1
locally it works fine tho (non-docker)
I fixed it by copying the .env also in the same folder as the scripts, which I dont think it should be necessary... no idea how else I could've solved it
n
Hey 👋 Glad to hear that you were able to solve the issue. If it helps this is an example from our official prisma-examples repository where we are spinning up a Cockroach DB database instance using docker. This might be helpful to you.