skip to Main Content

I want to explain first.

I have a domain and I connected it to Cloudflare so I can get free SSL.
Then I created a Linux (Debian 11) vm server on Google Cloud.

I’ve added A and CNAME records on my Cloudflare and I can access my site with my domain.

The problem is, I also can access my site using a static External IP from Google Cloud. Is this normal?

My site is tempvalidasi1.site

3

Answers


  1. Chosen as BEST ANSWER

    Thank you for your answer. I've found the solution from How can I prevent Google Compute Engine external ip for public and cloudflare whitelist for GCE?

    People can access using IP because I allow all IP (0.0.0.0/0) to access my site using External IP on my GCP instance


  2. If you want separate domain access in server you need use server-side tools like nginx. When you use nginx you can assign port, root directory and specific domain path in config which that calculate by user request.When users will access only to domain in this case users can see your site content, otherwise it is will not possible.

    Login or Signup to reply.
  3. Yes you can also access using IP and domain name actually domain in masking IP address.
    if you do need to access the website using an IP address is also possible.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search