Skip to content

A javascript routine to check and update your public ip to a namesilo ddns record value

Notifications You must be signed in to change notification settings

lemyskaman/namesilo_dynamic_dns_record_updater

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple Namesilo Nodejs Dynamic Domain Name System

This javascript program implements the http API from namesilo to update the value of an "Existing Resource Record " with your public ip address, polling it from ipyfy public service.

Requires

This script was developed and tested using:

Install

Clone the repository .

git clone https://github.com/lemyskaman/namesilo_ddns_record_updater.git

cd namesilo_ddns_record_updater

Install all node modules.

npm install 

Rename the file example_config.js to config.js. On linux you can do that with the next command:

mv config_example.js config.js 

Edit the file config.js filling the empty ("") config properties. Take this as an example:

var _ = require('lodash');


var config = {
     ipifyPublicHttpServiceQuery : "https://api.ipify.org?format=text",
     ipifyPollPeriod:"10000",//milisecs
     namesilo_target_domain : "kamansoft.com", //your main domain
     namesilo_target_resource_host : "test.kamanasoft.com", //a target value update subdomain
     namesilo_api_key : "b2fdef38c2932a3eb47f", //you must get an ip key from namesilo
     record_list_http_query_template : _.template("https://www.namesilo.com/api/dnsListRecords?version=1&type=xml&key=<%- apiKey %>&domain=<%- targetDomain %>"),
     update_http_query_template : _.template("https://www.namesilo.com/api/dnsUpdateRecord?version=1&type=xml&key=<%- apiKey %>&domain=<%- targetDomain %>&rrid=<%- targetResourceId %>&rrhost=<%- targetResourceHost %>&rrvalue=<%- value %>&rrttl=7207 ")
    }

module.exports = config;

Usage

If everything above is ok the just run the script.

npm start 

About

A javascript routine to check and update your public ip to a namesilo ddns record value

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published