I am attempting to use firebase-tools on a remote Linux server via Putty. There is no desktop running on this server.
When I run firebase login
Procedure on how to setup Firebase for CI and headless servers is described here: https://github.com/firebase/firebase-tools#using-with-ci-systems
The Firebase CLI requires a browser to complete authentication, but is fully compatible with CI and other headless environments.
- On a machine with a browser, install the Firebase CLI.
- Run firebase
login:cito log in and print out a new refresh token (the current CLI session will not be affected).- Store the output token in a secure but accessible way in your CI system.
There are two ways to use this token when running Firebase commands:
- Store the token as the environment variable
FIREBASE_TOKENand it will be automatically used.- Run all commands with
--tokenflag in your CI system.