-1

I have:

  • a domain hosted outside google (englishcampus.com.br)
  • a VM instance in Google Compute Engine running an application, with a static IP
  • a subdomain (erp.englishcampus.com.br) pointing to that VM, which is working fine

But as I'm trying to authenticate Google API (OAuth), I get an error message:

"Invalid parameter value for redirect_uri: Raw IP addresses not allowed: http://104.197.50.68:8069/google_account/authentication"

...showing that one cannot use an IP address to redirect. On the API credential I put "http://erp.englishcampus.com.br/google_account/authentication", assuming that erp.englishcampus.com.br points to the VM.

My question is: how can I have the VM responding under an URL, instead of the static IP address, so that the OAuth process work?

1
  • 1
    This question is being voted for closure because the author does not show a level of technical understanding or appropriate due diligence in researching the topic that the community judges as being a minimum barrier to participate.
    – Wesley
    Oct 1, 2015 at 2:26

1 Answer 1

2

Give the VM an A record for erp.englishcampus.com.br. This is how you make a domain name point to a ip address.

3
  • I see. This is working. But when I invoke the OAuth redirection, it rejects the URI because it has an IP address inside it: "104.197.50.68:8069/google_account/authentication".
    – Atila Tini
    Oct 1, 2015 at 4:49
  • the A record is working but the call resolves back to the VM IP.
    – Atila Tini
    Oct 1, 2015 at 4:51
  • Don't use the IP address as part of your URI, use the A record instead.
    – 84104
    Oct 1, 2015 at 16:05

Not the answer you're looking for? Browse other questions tagged .