Firebase-js-sdk: firestore.googleapis.com blocked by corporate firewall

Created on 13 Nov 2020  路  3Comments  路  Source: firebase/firebase-js-sdk

I'd like to reverse proxy firestore.googleapis.com through my own domain to avoid blocking by corporate firewalls. I can't find information, how to set the service URL and I'm wondering if this is supported at all.

function initializeApp(options: Object, name?: string): firebase.app.App;

I tried to derive the config from initializeApp, but it just takes an generic Object and the text does not mention something like a serviceUrl:

firebase.initializeApp({
  apiKey: "AIza....",                             // Auth / General Use
  appId: "1:27992087142:web:ce....",      // General Use
  projectId: "my-firebase-project",               // General Use
  authDomain: "YOUR_APP.firebaseapp.com",         // Auth with popup/redirect
  databaseURL: "https://YOUR_APP.firebaseio.com", // Realtime Database
  storageBucket: "YOUR_APP.appspot.com",          // Storage
  messagingSenderId: "123456789",                  // Cloud Messaging
  measurementId: "G-12345"                        // Analytics
});

The idea is that I setup and endpoint like /api/v1/external/firestore and reverse proxy the requests to firestore.googleapis.com

needs-triage

Most helpful comment

Thanks for this information!

All 3 comments

I found a few problems with this issue:

  • I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.
  • This issue does not seem to follow the issue template. Make sure you provide all the required information.

It looks like I have found it:

firebase.firestore().settings({ host: "..." });

Thanks for this information!

Was this page helpful?
0 / 5 - 0 ratings