One-line deploy
This step takes about 3 minutes.
What you'll need
Your one-time Doorman API Secret Key (how do I generate a secret key?)
Your Firebase project ID (how can I find my firebase project ID?)
Run the command
In order to deploy, we'll use run-doorman@latest
in the root of your app.
Make sure you have your API Secret Key handy.
The command looks like this:
Tip: If something errors, try running the command a few more times. If that still doesn't fix it, head to our website and live chat with us.
Next, you'll authenticate your Firebase account via Google.
Authenticate Google
After running the command, your browser will open. You should be prompted to log in to Google.
If you use multiple computer monitors, the browser may have opened in a different monitor. 👩💻
Sign in to Google with account that you used to make to your Firebase project.
Next, select Allow at the bottom.
Monitor your deployment
After authenticating, the deployment will take a few minutes. To monitor when its status, open the project on your Doorman dashboard.
Woohoo! Continue on to install the Doorman in your React Native app.
How to generate API Secret
Generating a secret key will render any previously-created keys useless and removing their deployment. You should only generate a secret key once.
Sign in to Doorman.
Open your project. If you don't have one yet, create one.
Go to the Deploy screen.
Scroll down to step 2.
Click "Create Secret Key"
Copy the key.
Find my Firebase project ID
Open your Firebase console and sign in
Copy the Project ID under the name
Behind the scenes
What's happening behind the scenes when you use our CLI?
From the command line, Doorman prompts you to log in to your Firebase account and deploys a cloud function on your behalf. This is all done locally on your machine – Doorman never receives any of your Google credentials.
The cloud function Doorman deploys first validates requests to ensure they're coming from Doorman (using your Doorman secret key). Next, then generates a custom auth token for the user requested by Doorman.
Last updated