I’m trying to allow the user to set variables before making the deploy. That is working for users that have already made a deploy, but the configuration fields are not beeing shown to users that are making their first deploy.
Can someone help me?
This is my netlify.toml setting:
[build]
command = "npm run build"
publish = "dist"
[template.environment]
ECOM_STORE_ID = "Your E-Com Plus Store ID"
ECOM_STORE_OBJECT_ID = "Your E-Com Plus Store Object ID"
Are people deploying using a “Deploy to Netlify” button in the repo or doing a “normal” deployment?
For a “normal” deployment, one solution would be to include those variables by adding them to netlify.toml before deploying.
If they are deploying via the web UI, in step three ( Build options, and deploy!) click “Show advanced” and then “New variable”. This will allow the environment variable to be added there and used for the initial deploy.
If there are other questions or this is needed in a “Deploy to Netlify” button, please reply here anytime.
We are using a “Deploy to Netlify” button, deploying via the web UI, where the users shoud insert these IDs.
If there is a way to make the enviroment variables be shown in the UI even in the first deploy we would appreciate it very much. This would be the best way for our users to make the deploy.