-
Notifications
You must be signed in to change notification settings - Fork 186
EAS Submit does not take ENV VARs (like APP_VARIANT) from profile or eas.json environment #3010
Copy link
Copy link
Open
Labels
needs reviewIssue is ready to be reviewed by a maintainerIssue is ready to be reviewed by a maintainer
Description
Build/Submit details page URL
No response
Summary
When running eas submit --profile production, and having eas.json configured with:
"production": {
"autoIncrement": true,
"channel": "production",
"environment": "production"
}The command does not take environtment variables configured in the production environment.
For example:
I use process.env.APP_VARIANT in my app.config.ts to determine the bundle identifier, and default to development if the env var is not set. I've noticed in eas submit that the env var is not set, to it submits with my dev bundle identifier.
I think it should work for eas submit in the same way it works for eas build according to https://docs.expo.dev/eas/environment-variables/
Managed or bare?
Managed
Environment
bunx expo-doctor
env: load .env.local
env: export APP_VARIANT EXPO_PUBLIC_SENTRY_DSN SENTRY_AUTH_TOKEN
15/15 checks passed. No issues detected!
Error output
No response
Reproducible demo or steps to reproduce from a blank project
- Set up the
APP_VARIANTenvironment variable in EAS for the production environment - Configure the production profile in
eas.jsonto use the production environment - Determine the bundle identifier in
app.config.tsto be based onprocess.env.APP_VARIANT - Run eas submit --profile production
- Observe that the
APP_VARIANTenvironment variable is not set
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
needs reviewIssue is ready to be reviewed by a maintainerIssue is ready to be reviewed by a maintainer