You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Do you want to request a feature or report a bug?
Request a feature
- What is the current behavior?
The CLI gets it's access token from ~/.netlify/config. This can be overridden with the --access-token flag.
- What is the desired behavior?
It would be helpful if the access token could be set with an environment variable.
Why? Because on the CI server, the config file won't be available so you need other means of passing the access token. I can use the cli flag, --access-token $NETLIFY_TOKEN but that means my build script will fail when running locally because the environment variable won't be available.
- Please mention your node.js, and operating system version.
Not relevant.
The text was updated successfully, but these errors were encountered:
Development on netlify-cli by netlify is basically over - all effort going into netlifyctl these days. However as a workaround, how about if in CI you did something like this?
if [ ! -z "$ACCESS_TOKEN" ] ; then
netlify deploy --access-token $NETLIFY_TOKEN
else
netlify deploy
fi
This has the added benefit that you can just turn off netlify deploy entirely by replacing the else clause for local development.
If that feels too dirty to you, we'll still accept PR's to add features to netlify-cli.
- Do you want to request a feature or report a bug?
Request a feature
- What is the current behavior?
The CLI gets it's access token from
~/.netlify/config
. This can be overridden with the--access-token
flag.- What is the desired behavior?
It would be helpful if the access token could be set with an environment variable.
Why? Because on the CI server, the config file won't be available so you need other means of passing the access token. I can use the cli flag,
--access-token $NETLIFY_TOKEN
but that means my build script will fail when running locally because the environment variable won't be available.- Please mention your node.js, and operating system version.
Not relevant.
The text was updated successfully, but these errors were encountered: