Search code examples
herokudnsipa-records

Point URL to different IP, A record


Example

Let's say we have a domain www.example.com.

This domain points to Heroku and we have functional website.

example.herokuapp.com
www.example.com

When we load the website

www.example.com

our website works and succesfully loading App on Heroku. Let's say it is running a Django framework (Python Environment)

There is another website that has different IP and is built in Ruby Rails for example and is running on different host provider.

If we load the website www.example.com, we are on the homepage, we can easily browse different pages like about, photos, videos etc.

Is there a possibility if I type

www.example.com/store/

that it would load that ruby rails website?

Let's remove possibilty moving the app from different provider to heroku or any other provider that www.example.com is on (or precisly were example.com points to in DNS).

Is it possible to map it somehow or point it in DNS to make it work like that?


Solution

  • Short answer: no.

    Longer answer, you could use a 301 redirect from /store/ to the other site, or a subdomain, like store.example.com. For more information, read up on DNS A records, as you suspected! Good luck!