Email forwarding with GCP Cloud DNS and Google Domain - google-cloud-platform

I am using Google domains and had an email forwarding set up to my Gmail account.
Recently I have set up Google Cloud DNS to be able to use Google Cloud CDN and speed up my site.
Unfortunately, when setting up Google Cloud DNS I had to change the default Google domain name servers. This has disabled email forwarding from Google domains.
Does anyone know how to set up email forwarding to Gmail directly from the Google Cloud Platform?

I managed to find a solution in the cloud-dns-discuss Google group.
Google Domains documentation to set up email forwarding with custom name servers recommends using Blank or # as Name/Host/Alias.
I was using #. After removing the # and leaving the Name/Host/Alias Blank, e-mail forwarding started working.

Related

How to move a domain from one project to another in Google Cloud Domains

I have mistakenly registered a domain in the wrong project from Google Cloud > Network Services > Cloud Domains.
Is there a way for me to move it in another project?
Google Domains is not project based. Domains are managed by the identity of the domain owner.
Google Cloud Domains is in preview and is project based. At this time, there is no method to move a registered domain from one project to another. You can export the domain to Google Domains. Note: The DNS servers for a domain can be located in any project and do not need to be in the same project as Google Cloud Domains. Before exporting the domain, check to see if your domain is already being managed by Google Domains here. You will need to be using the same identity that owns the registered domain. If the domain appears, go to the other project, create the DNS servers and then enter the servers into Google Domains on the DNS tab under Name Servers. You can also change the DNS servers while in Google Cloud Domains. Select "EDIT DNS DETAILS" at the top of the Google Cloud Domains console window.
If you mean that you created the DNS server in one project and you need to move the DNS server to another project then follow these steps. Create a new DNS server in the desired project, duplicate the DNS server resource records and then update the DNS server entries in Google Domains. Wait at least 24 hours and then delete the old DNS server.
If you mean that your registered your domain under the wrong Google Account (email identity), then you can transfer the domain to the desired Google Account. Login to Google Domains with the account that you own the domain. In the interface follow the Transfer a domain out section. Get the authorization code. In another browser window, login with the desired account and transfer in the domain using the transfer authorization code.

Linking Google cloud sql instance django website to google domain

I have created django website on Google cloud and its running on sql instance (https://school-website-272007.el.r.appspot.com).
I already have a google domain, and i want to link this to it.
I followed as below:
Created a VM instance on GCP and linked the external ip to my running sql instance.
Created Zone and 'A' / 'CNAME' in the Cloud DNS section.
Added the new DNS settings to Google domain - DNS settings under custom.
(used https://cloud.google.com/dns/docs/quickstart and other youtube links to perform)
But still my google domain is not able to link to the website (https://school-website-272007.el.r.appspot.com)
Can anyone help?
I recommend to use App Engine Custom Domains. With custom domains you can add the domain you may want to redirect to your App Engine app instead of using the appspot link.
While configuring the custom domain, it will tell you which DNS records you have to add to your DNS.

Connecting Google Domain to Google Cloud Instance

I've recently converted from using traditional registrars and started using Google for website hosting and domain registration. I've followed various guides and am currently infuriated at how hard it is to connect my domain owned by google to the google cloud instance while retaining email forwarding.
In order to point the domain to my VM in requires changing the nameservers. Once the name servers are changed then email forwarding stops working. I'm stuck in an infuriating loop. There has to be a better way.
Here's the process I followed
Google Domain > ExampleSite.com
Google Domain > support#examplesite.com (email forwarding to default gmail account)
Google Cloud > Create Wordpress VM instance
Google Cloud > Add DNS Records
Google Domains > Update Nameservers with info from Google Cloud DNS
Works, but email forwarding is immediately disabled unless I revert to default google nameservers, which stops the domain from pointing to the VM.
Please. Anyone. Help with a better way of doing this. Please. I'm so frustrated.
Thank you.
The reason why email forwarding breaks that your Cloud DNS is not configured with the necessary MX records. Here are the two possible solutions:
Add the MX records described here to your Cloud DNS configuration.
Revert back to Google Domain's name servers, which has the MX records built in. You can then set up your website by creating an A Record for the # record and www subdomain record to point to your GCE's IP address.
If all you want to do is to host a website I recommend (2), as it saves you the cost and complexity of having Cloud DNS as well as Google Domains.

Use wildcard subdomains for Google Cloud Functions

I'm trying to set up a wildcard domain on Google Cloud Functions. I've seen here that it's doable for Google App Engine. But how to do it for Google Cloud Functions?
Let's say the wildcard is *.singlelisting.co. I would like to reach a function named bigben from any of these subdomains 6.singlelisting.co or ns324.singlelisting.co.
So a user would reach bigben by visiting https://6.singlelisting.co/bigben or https://ns324.singlelisting.co/bigben
As far as I know the only way to get a custom domain for Cloud Functions is through Firebase Hosting.
Firebase Hosting does not support wildcard domain mappings, due to its reliance on letsencrypt.org for SSL certificates.

Receiving Incoming Email on Google Compute Engine Hosted Domain?

Current Setup :
Domain registrar - Godaddy.com
Domain Hosted on - Google Cloud Platform
CMS - Wordpress
I have a simple Wordpress website that is hosted on the Google Cloud Platform free tier. For any emails that need to go out of Wordpress (Password reset mails / notifications etc.), I have configured SendGrid as the SMTP relay and it works perfectly.
My problem now is how to receive incoming emails ?
I just want to setup a couple of email accounts for my domain and forward / import all incoming emails to my Gmail account.
All instructions point to Gsuite, which will be an overkill at this time since I will not be using any of its features. I just need to receive occasional incoming emails.
While there are literally 100's of articles on configuring outgoing emails via SendGrid / MailJet etc., there are no useful articles on how to receive incoming emails.
Google search mostly turns up an old video about using a free Zoho account; which itself is now become a paid app.
Tried so far :
[1] Tried to set-up email forwarding on Godaddy. Nothing worked. Since the Nameservers are pointed to Google Cloud DNS, I believe Godaddy forwarding will not work.
[2] Checked SendGrid options, could not find anything.
[3] Trawled through Google for several hours, could not turn up anything useful.
I would sincerely appreciate any relatively straight-forward solutions / suggestions / pointers for receiving incoming emails - Either through the GCP or outside.
Just add an mx record to your domain that point to the IP address of the machine hosting your mail service .
Here's how you can add the record :
https://godaddy.com/help/add-an-mx-record-19234