Services/DDNS: Difference between revisions

From DcUsers
mNo edit summary
 
(2 intermediate revisions by the same user not shown)
Line 3: Line 3:
| prerequisite =
| prerequisite =
| account = local
| account = local
| ipv6 = false
| ipv6 = true
| security_notes = This service is secured using keys.
| security_notes = This service is secured using TLS, web certificates and a specific account (separate from your main account).
}}
}}


Line 10: Line 10:
== Access ==
== Access ==


To use this service, ask for an account to an administrator. For each IP you need to track, you should be provided with:
To use this service, ask for an account to an administrator. For each IP you need to track, you should provide with (explanations follows):
* secondary account suffix (characters allowed: letters, numbers)
* HostID
* hostname suffix (characters allowed: letters, numbers, dash)
* AuthP lines
* AuthQ lines


The secondary account prefix is used to create your secondary account name, based on your main account name. If your main account is called ''toto'' and the secondary account prefix is called ''home'', then the secondary account name would be ''toto-home''. It is used as service username in the configuration, and along with a password, identify yourself as owner of the DNS entry.
You also need to have the DHIS port opened, which is: UDP 58800.

The hostname prefix is used to create the DNS entry for your host. If you use ''house'' as prefix, then the DNS entry would be ''toto-house.ddns.duckcorp.org''.

It is possible to have multiple DNS names associated with the same account. So you could have another prefix ''manor'' and the additional DNS entry would be ''toto-manor.ddns.duckcorp.org''.

=== Installation on Debian ===

Currently the software is not packaged, so a few manual steps are needed.

Install the dependencies:
apt-get install kwalify ruby-curb ruby-safe-yaml ruby-log4r

Install the Software:
cd /opt
git clone https://vcs-git.duckcorp.org/duckcorp/ddns.git
cd ddns
ruby setup.rb config --bindir=bin --rbdir=lib --datadir=data --sysconfdir=conf --localstatedir=var --shebang=never
ruby setup.rb setup
mkdir -p conf/ddns var/log/ddns


=== Configuration on Debian ===
=== Configuration on Debian ===


Create ''/opt/ddns/conf/ddns/myip.conf'' containing:
Install the software:
---
apt-get install dhis-client
url: "https://myip.duckcorp.org/"
timeout: 3

Create ''/opt/ddns/conf/ddns/client.conf'' containing:
---
log:
path: "./var/log/ddns/"
regip:
url: "https://ddns.duckcorp.org/"
user: <secondary-account-name>
passwd: <secondary-account-password>
timeout: 3
profiles:
<dns-entry>:
ipv4: auto
ipv6: auto
and replace fields into angle brackets using your own credentials and DNS info.


The ''profiles'' block can hold as many DNS entries as you need; they may not be on the same site though.
And add a block in your configuration file ''/etc/dhid.conf'' like this:
{
HostID &lt;hostid&gt;
ISAddr ddns.duckcorp.org
Refresh 1200
AuthP &lt;auth-p-line-1&gt;
AuthP &lt;auth-p-line-2&gt;
AuthQ &lt;auth-q-line-1&gt;
AuthQ &lt;auth-q-line-2&gt;
}


You can find more information on the various configuration parameters on the [https://projects.duckcorp.org/projects/ddns/wiki/Configuration#RegIP-client-ddns-client DDNS project wiki].
Restart the service:
service dhis-client restart


== Technical Details ==
== Technical Details ==


This service is made using:
This service is made using:
* [http://www.dhis.org/ DHIS]
* [https://projects.duckcorp.org/projects/ddns DDNS]

Latest revision as of 09:44, 3 March 2018

Service 'DDNS'
Description Automatically find a changing (dynamic) IP address (home address for example) using this service.
Prerequisite None
Account Local (registration required) IPv6 Ready Yes
Security Notes This service is secured using TLS, web certificates and a specific account (separate from your main account).


Access

To use this service, ask for an account to an administrator. For each IP you need to track, you should provide with (explanations follows):

  • secondary account suffix (characters allowed: letters, numbers)
  • hostname suffix (characters allowed: letters, numbers, dash)

The secondary account prefix is used to create your secondary account name, based on your main account name. If your main account is called toto and the secondary account prefix is called home, then the secondary account name would be toto-home. It is used as service username in the configuration, and along with a password, identify yourself as owner of the DNS entry.

The hostname prefix is used to create the DNS entry for your host. If you use house as prefix, then the DNS entry would be toto-house.ddns.duckcorp.org.

It is possible to have multiple DNS names associated with the same account. So you could have another prefix manor and the additional DNS entry would be toto-manor.ddns.duckcorp.org.

Installation on Debian

Currently the software is not packaged, so a few manual steps are needed.

Install the dependencies:

 apt-get install kwalify ruby-curb ruby-safe-yaml ruby-log4r

Install the Software:

 cd /opt
 git clone https://vcs-git.duckcorp.org/duckcorp/ddns.git
 cd ddns
 ruby setup.rb config --bindir=bin --rbdir=lib --datadir=data --sysconfdir=conf --localstatedir=var --shebang=never
 ruby setup.rb setup
 mkdir -p conf/ddns var/log/ddns

Configuration on Debian

Create /opt/ddns/conf/ddns/myip.conf containing:

 ---
 url: "https://myip.duckcorp.org/"
 timeout: 3

Create /opt/ddns/conf/ddns/client.conf containing:

 ---
 log:
   path: "./var/log/ddns/"
 regip:
   url: "https://ddns.duckcorp.org/"
   user: <secondary-account-name>
   passwd: <secondary-account-password>
   timeout: 3
 profiles:
   <dns-entry>:
     ipv4: auto
     ipv6: auto

and replace fields into angle brackets using your own credentials and DNS info.

The profiles block can hold as many DNS entries as you need; they may not be on the same site though.

You can find more information on the various configuration parameters on the DDNS project wiki.

Technical Details

This service is made using: