Firebase Custom Domain Needs Setup - Domain.com - firebase

Here is what I completed
my website is deployed to firebase with URL https://lizart-io.web.app/
I purchased a custom domain https://lizart.io on domain.com
followed the steps from firebase documentation to set it up, these instructions were provided here: https://firebase.google.com/docs/hosting/custom-domain
verified ownership of the domain by adding two TXT records to Domain.com
Now the Error/Issue I encountered: Firebase says that my custom domain Needs Setup.
Firebase Dashboard Status
Firebase Dashboard
Domain.com DNS settings
How do I complete the last setup? Where did I miss a step?
Thank you very much in advance all!

Related

Google Firebase cannot verify ownership of Domain.com domain

I purchased a domain from domain.com and am trying to connect my firebase project to it. I have copy pasted the TXT record as instructed by Firebase, but it still cannot verify my ownersip of the domain. This is a copy of all of the DNS records on domain.com
This is the error given by firebase
I don't recall where the A address came from. Any ideas on how to confirm the verification?

concerns about required A records for setting up Firebase Dynamic Links with a custom subdomain

In setting up our own subdomain to handle Firebase Dynamic Links using these docs, the wizard says to put the A records at example.com in our DNS. I'm getting pushback from our network administrators who are wary of creating an A record at the root of our domain, which is a large e-commerce web site.
A couple of concerns/questions about this:
The IP addresses required (151.101.1.195 and 151.101.65.195) point to non-Google servers (looks like Fastly), which is a bit alarming - it seems strange that Google would outsource their deep link hosting.
We don't want all of our e-commerce traffic (coming through example.com) to be subject to these A records. Is it possible to put the A records at link.example.com instead?
The Firebase documentation on using a custom domain for dynamic links has this note:
To use a custom domain for Dynamic Links, the domain must point to Firebase Hosting. If you have a domain you want to use with Dynamic Links and the domain points to a different host, you can either move to Firebase Hosting or create a subdomain hosted by Firebase, which you can use for Dynamic Links.
So you can indeed use a subdomain for the dynamic links. In that case, just set up the subdomain in Firebase hosting. You'll need the same TXT record as normal, to prove that you have access to the domain, but then just map the subdomain (e.g. links) for the A record.
Here is the answer I received from Firebase support about these my two concerns/questions:
Regarding Fastly, Firebase uses this subprocessor to deliver content and managed services on Firebase Hosting. For more details you could check the list of Subprocessors used by Firebase on this doc.
It's possible to use a subdomain as your Firebase project's FDL domain. You'd need to create a subdomain (link.example.com) on your domain's DNS provider and connect it to Firebase Hosting. You could check out this guide for more details.

How to setup domain & its sub domain to different Firebase hosting projects

Suppose my domain is mydomain.com, and subdomain subdomain.mydomain.com. I got it from Godaddy.
What I want
I want to run different websites on each.
mydomain.com -> Website 1
subdomain.mydomain.com -> Website 2
How I setup so far
Website 1 is hosted on Firebase project 1 and accessible via default URL firebase-projectid.firebaseapp.com.
Website 2 is hosted on Firebase project 2 and accessible via default URL.
Both Firebase projects are on same Google account.
What I have done successfully so far
I started with mydomain.com -> Website 1
Verified domain by adding TXT record provided by Firebase project 1.
Added couple of A records to point domain to Firebase project 1 hosting.
So far so good, and mydomain.com is working fine.
What is not working
Now I want to host subdomain.mydomain.com -> Website 2 with Firebase project 2.
I started with custom subdomain, added subdomain.mydomain.com. Firebase had already verified domain and directly provided me ip address for A records. I added both A records on my domain registrar.
As far as I understand, these are only steps needed. But subdomain.mydomain.com is not working and Firebase still shows status of subdomain as Needs Setup.
Observations
Two things I observed seems strange to me.
IP address provided by Firebase for both projects mydomain.com and subdomain.mydomain.com are same. Not sure if this is normal or not.
subdomain.mydomain.com with A records, is not propagating when checked on https://dnschecker.org/. However, if subdomain is added via Godaddy Forwarding option, then it start propagating in few minutes.
Questions
BTW, is it really possible to host domain and its subdomain on Firebase running different websites?
If yes, then is there any other step which I am missing?
Any idea why subdomain.mydomain.com is not propagating. I checked just after 10 mins. May be I need to wait longer?
Anything wrong I am doing to setup subdomain.
I tried exploring other threads but couldn't understand what I am doing wrong. Any help will be appreciated.
After scratching my head for few more hours I found issue at Godaddy side. While adding subdomain A record, I was providing host as subdomain.mydomain.com, which was wrong.
Instead of subdomain.mydomain.com host should have been subdomain only. After updating host it started propagating in few seconds, and status on Firebase is Pending. After a minute, subdomain.mydomain.com is working fine.

Firebase hosting with only ONE A record

I have my client's domain registered via 1and1.com
To connect the domain to the Firebase hosting, Firebase asks me to add TWO A records with 2 IPs. In 1and1 we can only add ONE A record. Yesterday Firebase sent me this message by mail
Please re-verify ownership of www.*******.com on
*******-website. The previous verification for this domain has
been invalidated. You have 1 day to re-verify ownership of
www.*******.com before it is removed from Firebase Hosting,
which will stop all content from being served from the domain. Please
visit the Firebase Hosting Panel to start the re-verification process.
Today the website was disconnected.
I reconnected the domain to the Firebase hosting through the Firebase control panel and got the website up again. But the Firebase control panel says it still needs setup
I am sure it will disconnect it again soon. How to solve that? (I already called 1and1 and they told me no way I would be able to add another A record.)
I set up in the same way a website (https://lasi17.snola.es/) and it seems to work with only one A record pointing out to the Firebase IP.
In my case, I just changed the option in Hosting -> Domains -> Your custom domain (in my case lasi17.snola.es) -> Process traffic in this domain ("Edit" under the kebab menu). After that, the domain works as usual with only one A record configured.

Pointing domain and subdomain to the same firebase app

Custom domain is currently setup with A record pointing to the IP of the firebase AND wildcard CNAME record pointing to the same app.
dig +short mydomain.com
151.101.65.75
151.101.1.75
dig +short abc.mydomain.com
myapp.firebaseapp.com.
app-cert.firebaseapp.com.
151.101.65.75
151.101.1.75
The problem is that "abc.mydomain.com" is redirecting to "mydomain.com" with a 301 response.
Is the problem in how the domain is setup or on the firebase end?
EDIT reply from the firebase support is:
"Unfortunately, since you've already connected your domain mydomain.com your firebase app, all redirects will go through that URL. and not to your firebase app.
"
This reply is so confusing and makes no sense IMO.
Update 2020-03-30
For several years now it's actually been entirely possible to have a subdomain pointing to a different Firebase Hosting site than the apex domain. This answer has been out of date. Happy Hosting!
Firebase Hosting presently only allows one canonical domain for your project -- if you specified mydomain.com and then point abc.mydomain.com to Firebase Hosting, it will redirect, as you saw.
We're considering some improvements in this area for the future, but at present all non-canonical domains will redirect.

Resources