HOWTO create subdomain pointing to external server, if even possible

Discussion in 'Installation/Configuration' started by Appie Thrasher, May 5, 2025.

  1. Appie Thrasher

    Appie Thrasher Member HowtoForge Supporter

    So here is what I was thinking of..
    I am pooking around with HomeAssistant to get a smart house, I have a domain and that is working fine on ISPConfig like mydomain.com.
    I would like to try to get a subdomain like ha.mydomain.com to point to my nas server at home, were homeassistant is on and working, but cant seem to get it working, or how to configure this..
    So can this be done, and howto do it, or dont use a subdomain or etc etc..

    I tried to set up a subdomain and than make a A record: ha, in mydomain.com to point to my nas ip that did not work.
    If I make a new site with the subdomain it points to my website at mydomain.com

    TIA Appie
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Is the ISPConfig server on the same local (gome) network than your home assistant? Or is the ISPConfig server in a data center and the home assistant at home behind a router?
     
  3. Appie Thrasher

    Appie Thrasher Member HowtoForge Supporter

    The last option server (VPS) is in datacenter and NAS is at home behind my router...
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Does your router has a fixed external IP address?
     
  5. Appie Thrasher

    Appie Thrasher Member HowtoForge Supporter

    Yep
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    The easiest way is probably to point a subdomain of your domain to the public IP address by creating a DNS A-Record for it on the DNS server responsible for your domain. This does not have to be your ISPConfig server; it can also be the DNS server at the hoster where you registered the domain.
     
  7. Appie Thrasher

    Appie Thrasher Member HowtoForge Supporter

    Yep that's what I was trying to do, but cant get it to work..
    I made a DNS A-Record in mydomain.com for the subdomain and pointed that A-Record (subdomain) to the IP from the router, and opened in the router a rule to point subdomain.mydomain.com to the internal NAS IP with its corresponding port (192.168.1.10:1234), with running HomeAssistant (example:subdomain.mydomain.com)
    but correct me if I am wrong... to dit it this way
     
  8. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    did you actually set it to use port 1234 or was that just for an example?
    home assistant, by default, uses port 8123

    also, no idea what router you have, but is just creating a rule to point the subdomain to the internal nas ip enough?
    it might do that for all ports, it might only do it on certain ports. you might need to create a specific port forwarding rule.
     
  9. Appie Thrasher

    Appie Thrasher Member HowtoForge Supporter

    Yep just as example

    I know have some other ports open already to point to my music etc..

    But thanks for thinking along...
    And TBH this isn't a big deal, as I said I am still just fooling around in HA, and thought this was a quick fix but its not, so for now I am just going to use it local, so I can test and set things up and will try it again when I really need this external acces, maybe just get a new domainname just for HA because they don't cost a lot nowadays,, we will see

    Thanks Every one

    Appie
     
    Anton Hofstede likes this.

Share This Page