Replies: 1 comment
-
We don't currently capture this in our model, but could. For context, how it works today, we take the whole content of a file input (the |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Summary
In
turbo.json
I have a build task that has.env.local
insideinputs
option (as recommended in the official turbo docs).in the same
turbo.json
I have some global env vars that are used in the build process:]
My
checks.yml
in github actions uses those envs:If a user runs
turbo build
with this.env.local
content:The local build output and the CI build output should be equivalent but there will never be a cache hit cause in CI
.env.local
won't be defined, so turboinputs
(and generated cache) will be always different .Is there a way to address that setup?
Thanks in advance!
Examples
Scenario 1
I have a turborepo with, for instance, a nextjs app and some packages.
I have a
github action
to:build
scripte2e tests
pointing to that buildIf a user locally runs a build with the same envs and pushes it to the remote cache, I would expect CI to get the build from the remote cache.
Scenario 2
Vercel runs preview deployments in every PR but, even if using the same env values, it will never hit user cached builds due to the same reason above (users run builds with
.env.local
while vercel runs builds with plain system envs defined in the vercel console).Beta Was this translation helpful? Give feedback.
All reactions