The website example.com is hosted with bluehost(with cpanel) and the domain is registered with a different service provider. How do i create a sub domain(web.example.com) for example.com and have it point to the hosting (for the sub domain alone) in google cloud vm instance(ubuntu 16.04) running LAMP stack.
1 Answer
Since you have hosted your main domain through cpanel, updating the DNS records there will give you the solution. You can follow the below steps
- Login to cpanel.
- Add an “A” record web.example.com with IP address of the LAMP stack VM running in Google cloud.
You can find details on adding a record in cpanel here
On a side note, if you are using an Ephemeral IP for your LAMP Stack VM you might risk getting a new IP if your instance shuts down which will require a change in the configuration, therefore having a static IP is recommended. Keep in mind that static IPs are free of charge as long as they are assigned.
-
thank you, can something like this be done at the "Manage DNS" at where the domain is registered with and not at the hosted cpanel ? if possible how ? Oct 5, 2017 at 11:04
-
-
-
I can only see this option in their customer care management page [1]. Select "Service Type" as "Domain" and "Problem Type" as "A record Change" , then fill the personal fields and submit. [1] net4.com/aspx/general/customer-care.aspx– DigilOct 13, 2017 at 16:02