My automatic builds don't use my environment variables
Unanswered
Giant Chinchilla posted this in #help-forum
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
I always have to rebuild my automatic builds after a git push. Otherwise my project gets build with no environment variables.
31 Replies
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
I don't see any errors min my build logs
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
Are you using vercel?
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
Yes sir
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
You can select your project, then deployments and settings
There you can change and set your desired environment variables
As I think that the .env is not loaded when building in vercel
Interesting
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
My builds always work the second time I build them. It's like when the cache is used, the env vars are not set
It's killing my CI/CD flow lol
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
![Image](https://cdn.discordapp.com/attachments/1163852496834400296/1163854427208294511/IMG_2609.png?ex=654116e6&is=652ea1e6&hm=217a00535c4e5d9c23aa9d95bf157a9cbe04523030211ce970fc8c69b920c4a2&)
![Image](https://cdn.discordapp.com/attachments/1163852496834400296/1163854427640320120/IMG_2610.png?ex=654116e6&is=652ea1e6&hm=cf6cf0498eaa71de595ec90d9c56532261f031449f602724b10e3bdece598e9d&)
![Image](https://cdn.discordapp.com/attachments/1163852496834400296/1163854428407865404/IMG_2611.png?ex=654116e7&is=652ea1e7&hm=f748bdad2dc9cc6e4bb10a305bdfca1ab14348153b55c5fbee6cbee271ae0d58&)
![Image](https://cdn.discordapp.com/attachments/1163852496834400296/1163854428961525881/IMG_2612.png?ex=654116e7&is=652ea1e7&hm=d3b51448813ced6372aef67ba607abbafe9487954db2ae2bec9ec3669d09d3bb&)
So when you go to this page you have all your variables that you want?
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
![Image](https://cdn.discordapp.com/attachments/1163852496834400296/1163854694871994470/image.png?ex=65411726&is=652ea226&hm=8cf6d6348e43f4f20c9d9e4ded2a1e8de8248e3e27e78249aef41eea95ccc0f6&)
Yes, for all 3 of my apps.
All 3 have this issue also
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
When you build, do you use build cache?
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
locally or in Vercel?
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
Vercel
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
Yes
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
there’s like a checkbox
Try re building without it checked
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
that's what works
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
?
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
I mentioned I had to rebuild my projects for them to work
That's what I do. Rebuild them with build cache disabled
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
Oh, are you having issues with the automatic build when pushing changes with git
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
yes
those builds, always fail
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
Idk about that, there might be a setting somewhere
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
?
![Avatar](https://cdn.discordapp.com/avatars/830089505544732674/d50a2dc134522d9629560f70836ed711.webp?size=256)
SharpieMaster
On vercel
![Avatar](https://cdn.discordapp.com/embed/avatars/2.png)
Giant ChinchillaOP
Hmmm I'll keep poking around. Thank you!