Skip to main content

Bot for domeneshop.no to keep your dns records updated with correct ip for your self hosting sites and services

Project description

Domeneshop.no DNS boot

Bot for users of domeneshop.no. Keep your dns records updated with public ip for your self hosted sites and services.

Only IP will be updated by the bot; record type, ttl and hostname will remain the same

Installation

pip3 install domeneshop-bots

Usage

See the documentation at https://api.domeneshop.no/docs/ for help on how to acquire your API credentials.

1. Fill inn API credentials and domains to track

{
   "api":{
      "token":"<your-domeneshop.no-token>",
      "secret":"<your-domeneshop.no-secret>"
  },
  "track": [
    {
      "domain": "yourdomainA.com",
      "hosts": ["subdomainA", "subdomainB", "subdomainC"]
    },
    { "domain": "yourdomainB.com", 
      "hosts": ["@", "www"] 
    },
    { "domain": "yourdomainC.com", 
      "hosts": ["@", "www", "subdomain"] 
    }
  ]
}

Hostname defaults

2. Fire the bot up, example loading json from file

import json
from domeneshop_bots import DNSBot


if __name__ == "__main__":
    with open("./config.json", 'r') as file:
        config = json.loads(file.read())
        bot = DNSBot(config)
        bot.start()

3. Set up a cron job, and you are done!

Or not. In any case you know what to do!

Authors

License

This project is licensed under the MIT License - see the LICENSE file for details

Acknowledgments

Thanks to domeneshop.no for creating an API!!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for domeneshop-bots, version 0.0.2
Filename, size File type Python version Upload date Hashes
Filename, size domeneshop_bots-0.0.2-py3-none-any.whl (6.2 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size domeneshop-bots-0.0.2.tar.gz (4.3 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page