Navigation

    Netgate Discussion Forum
    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search

    Dynamic DNS + one.com?

    Swedish
    5
    14
    1211
    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.
    • B
      biifer last edited by

      Försöker hjälpa min far som har en domän och webhosting hos one.com. Är det möjligt att använda Dynamic DNS i pfSense och uppdatera DNS som ligger hos one.com? Tanken är att ha kvar webhosting, mail o.s.v hos one.com men ha vissa subdomäner "hemma". Någon som har provat detta?

      1 Reply Last reply Reply Quote 1
      • L
        Lugico last edited by Lugico

        I made a python script that lets you dynamically change the IP address a dns entry is pointing to.
        So far it only works for type A record subdomains. If you need a different type, please try to reconfigure the script yourself. If you're not experienced with python, you can contact me and i will try to adapt the script.
        http://lugico.de/ddns.py
        execute it like this:

        python3 ddns.py youripaddress
        

        Run this every once in a while, maby through crontab, and you should be good.

        you can get your ip address in plain text from this address: https://api.ipify.org/?format=text

        combining the two could look like this (on linux):

        IP=$(curl https://api.ipify.org/?format=text); python3 my_ddns.py $IP
        

        Also, i dont speak swedish, i used google translate.
        If you need any help using the script, feel free to contact me through this email: minecraft.luca@gmx.de or discord: Lugico#4952

        T 1 Reply Last reply Reply Quote 1
        • T
          Technoid.se @Lugico last edited by

          @Lugico

          Thank you for the script, it works perfectly for me 😃

          H 1 Reply Last reply Reply Quote 1
          • H
            hellfire @Technoid.se last edited by

            @technoid-se hi! is it still working?, been looking everywhere for something like this.

            L 1 Reply Last reply Reply Quote 0
            • L
              Lugico @hellfire last edited by

              @hellfire Yes the script should still be working, but you won't need to get your IP address beforehand andymore. The script will do that for you. I can send you an updated version, that is even simpler to use.

              1 Reply Last reply Reply Quote 1
              • L
                Lugico last edited by Lugico

                Ok for everyone still finding this thread:

                I made a new, updated version, that is much simpler to use.
                https://lugico.de/one_com_ddns.py

                Edit the file beforehand to fit your needs. All the things you might have to change are in the top few lines. Execute it like this:

                python3 one_com_ddns.py
                

                python can be downloaded and installed from here: https://www.python.org/downloads/
                or on debian / ubuntu based machines, including raspberry pi OS, it can be installed using apt:

                sudo apt-get install python3
                

                You will also need to install the requests package.

                sudo pip3 install requests
                

                or

                sudo pip install requests
                

                on windows just remove the "sudo"

                @hellfire

                H 2 Replies Last reply Reply Quote 1
                • H
                  hellfire @Lugico last edited by

                  @lugico Thanks a lot, this well spare me 3rd party apps & the monthly verification.

                  I'm adding some keywords to make users find this (both swedish and English) :

                  dynamic ip one.com, update DNS automatically with your dynamic ip
                  dynamiskt ip one.com, uppdatera dns automatiskt med ditt dynamiska ip

                  1 Reply Last reply Reply Quote 0
                  • H
                    hellfire @Lugico last edited by hellfire

                    @lugico couldn't get it to work, got username, PW, and id number, domain everything is correct.
                    I noticed the id number is different depending on what subdomain you want to change..

                    {"result":null,"metadata":{"messages":[{"text":"No matching order found for current user matching requested domain name","code":"CRMRST_000302","arguments":null,"type":"error"}]}}
                    89.160.xxx.xxx (my ip)
                    
                    L 1 Reply Last reply Reply Quote 0
                    • L
                      Lugico @hellfire last edited by

                      @hellfire that looks like the output from the old script. try using the new one
                      https://lugico.de/one_com_ddns.py

                      H 2 Replies Last reply Reply Quote 1
                      • H
                        hellfire @Lugico last edited by

                        @lugico will try, your previous link to the new script, links to the old one...

                        1 Reply Last reply Reply Quote 0
                        • H
                          hellfire @Lugico last edited by

                          @lugico it worked fine!
                          .. now I just need to learn python, so it can be tweaked (would be great if it saved the last updated ip and checked if the ip has changed before it logs in and update it)

                          L 1 Reply Last reply Reply Quote 0
                          • L
                            Lugico @hellfire last edited by

                            @hellfire I just added this feature. If you click the link again you should get the new version. It saves the last IP address in a file ("lastip.txt") and only if the content of the file and the current IP address don't match, the script gets executed.

                            H 1 Reply Last reply Reply Quote 1
                            • H
                              hellfire @Lugico last edited by

                              @lugico Works perfect! thx a lot!

                              1 Reply Last reply Reply Quote 1
                              • viktor_g
                                viktor_g last edited by

                                feature request created: https://redmine.pfsense.org/issues/11293

                                1 Reply Last reply Reply Quote 1

                                Products

                                • Platform Overview
                                • TNSR
                                • pfSense
                                • Appliances

                                Services

                                • Training
                                • Professional Services

                                Support

                                • Subscription Plans
                                • Contact Support
                                • Product Lifecycle
                                • Documentation

                                News

                                • Media Coverage
                                • Press
                                • Events

                                Resources

                                • Blog
                                • FAQ
                                • Find a Partner
                                • Resource Library
                                • Security Information

                                Company

                                • About Us
                                • Careers
                                • Partners
                                • Contact Us
                                • Legal
                                Our Mission

                                We provide leading-edge network security at a fair price - regardless of organizational size or network sophistication. We believe that an open-source security model offers disruptive pricing along with the agility required to quickly address emerging threats.

                                Subscribe to our Newsletter

                                Product information, software announcements, and special offers. See our newsletter archive to sign up for future newsletters and to read past announcements.

                                © 2021 Rubicon Communications, LLC | Privacy Policy