<@UCZMXEP3J> How do I do environment variables in ...
# orm-help
c
@Harshit How do I do environment variables in my prisma.yml exactly? I’m trying to follow the documentation here: https://www.prisma.io/docs/1.2/reference/service-configuration/prisma.yml/using-variables-nu5oith4da I have something like this:
Copy code
endpoint: ${env:DB_API_URL, <https://us1.prisma.sh/my-id/my-app/dev>}
It’s not super clear how defaults should work EXACTLY. Your documentation shows:
otherYamlKey: ${src:myVariable, defaultValue}
without the string in quotes or anything but it doesn’t work like that. Also, I’d really like to use the
.env
file referenced here:
if the --dotenv argument was omitted, a file called .env in the same directory
but it’s not working. It’s unclear for the documentation: 1. “In the same directory”. Is that as the root where you’re running the command from, or as the prisma.yml file 2. Can you give an example of what this file should look like? Is it JSON, YML, other? I created a file with 1 line in it and it didn’t work.
Copy code
DB_API_URL=<https://us1.prisma.sh/my-id/my-app/dev>