Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


    Cloudron Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular

    Solved Custom DNS Server in local network

    Support
    unbound dns
    3
    6
    518
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • necrevistonnezr
      necrevistonnezr last edited by girish

      Hi,

      I’ve seen https://docs.cloudron.io/networking/ but can’t figure out how to point my local Pi-Hole. I’m using the www.dietpi.com implementation that comes with unbound on a separate Pi.

      I have created /etc/unbound/unbound.conf.d/custom.conf and added

      server:
          private-domain: "cloudron.lan"
          domain-insecure: "cloudron.lan"
      
      forward-zone: 
          name: "cloudron.lan"
          forward-addr: 192.168.1.20
      

      (or is cloudron.lan just an example?)

      Note that my local router is pointed to the same DNS server.

      girish 1 Reply Last reply Reply Quote 0
      • girish
        girish Staff @necrevistonnezr last edited by

        @necrevistonnezr If I understand correctly, you want to make Cloudron use the pi to resolve all the DNS queries?

        The configuration listed in the docs is meant to tell unbound that any queries for cloudron.lan (this is just the name of your internal network, so just an example used in the config) should go to 192.168.1.20 (the internal DNS server). So, it won't make all the queries go to the PI, just cloudron.lan queries.

        I haven't tried it but as per https://wiki.alpinelinux.org/wiki/Setting_up_unbound_DNS_server , if you put the below it will forward everything:

        forward-zone:      
                name: "."
                forward-addr: <your pi ip>
        
        K necrevistonnezr 3 Replies Last reply Reply Quote 2
        • K
          khadanja @girish last edited by khadanja

          This post is deleted!
          1 Reply Last reply Reply Quote 0
          • necrevistonnezr
            necrevistonnezr @girish last edited by

            @girish Thanks, just adding that to custom.conf worked!

            1 Reply Last reply Reply Quote 0
            • K
              khadanja @girish last edited by khadanja

              @girish I have a similar issue so instead of starting a new thread I thought I'll post here. My VM running cloudron is unable to resolve nameservers since installing unbound on my router. Came across this thread and added the below lines to /etc/unbound/unbound.conf.d/custom.conf
              server:
              private-domain: "cloudron.lan"
              domain-insecure: "cloudron.lan"
              forward-zone:
              name: "cloudron.lan"
              forward-addr: 192.168.1.1
              It worked for few days and broke again today, access to cloudron still works but when logged on to the VM it cannot resolve DNS queries, hope it makes sense. Any ideas why DNS resolution works intermittently?

              girish 1 Reply Last reply Reply Quote 0
              • girish
                girish Staff @khadanja last edited by

                @khadanja Is your idea to forward all queries ? The example config you pasted will only forward DNS queries for cloudron.lan (sic). You need the config in https://forum.cloudron.io/topic/5756/custom-dns-server-in-local-network/2 to forward all queries to your router.

                1 Reply Last reply Reply Quote 0
                • Referenced by  girish girish 
                • First post
                  Last post
                Powered by NodeBB