Skip to content

Latest commit

 

History

History
80 lines (53 loc) · 3.86 KB

index.md

File metadata and controls

80 lines (53 loc) · 3.86 KB
layout title nav_order
default
Home
1

Introduction

ddclient updates dynamic DNS entries for accounts on a wide range of dynamic DNS services.

This is applicable to a wide range of use cases. It's commonly used when you have an IP address that changes regularly (e.g. on a residential network), that you want to keep service pointing at (e.g. your domain name).

Installation

See the GitHub README.

Configuration

ddclient has two primary means of configuration:

  • (Recommended) The ddclient.conf file, which defaults to /etc/ddclient/ddclient.conf.
  • Passing in arguments via the command line.

There are three key pieces to configuring ddclient:

Example

A typical configuration file looks like:

# General config
daemon=300

# Router
usev4=webv4,webv4=ipify-ipv4

# Protocol
protocol=dyndns2
login=myUsername
password=myPassword
myhost.dyndns.org

With this config, executing ddclient would start a daemon that every 300 seconds would:

  1. Get your IPv4 address from the ipify web service.
  2. Login to your dyndns account with the given username and password, and update the myhost.dyndns.org domain to your current IPv4 address.

You can set up ddclient to run on automatically using other packages on your system, such as systemd, cron, dhclient, dhcpc and others. There are additional sample startup scripts in the GitHub repository.

Using environment variables

As of version 3.11.0_1, ddclient supports using environment variables inside the configuration file. By appending '_env' to a parameter, ddclient will interpret the value of that parameter as the name of an environment variable and use the value of that environment variable as the configuration value. This allows to keep sensitive information such as the login or password outside of the configuration file.

login_env=DDCLIENT_LOGIN
password_env=DDCLIENT_PASSWORD
myhost.dyndns.org

This example config file will use the value of the environment variables DDCLIENT_LOGIN and DDCLIENT_PASSWORD as the login and password for the domain myhost.dyndns.org respectively.

Command-line arguments

For simplicity, it's recommended you use the ddclient.conf file over command line arguments. If you can't use the default location, you can use the file argument only to read config from a different file, e.g. ddclient -file ddclientCustom.conf

However, any arguments can also be provided via the command line when invoking ddclient. For example:

ddclient -daemon 300 -protocol dyndns2 -login myUsername -password myPassword myhost.dyndns.org

ddclient prioritizes command line arguments, then falls back to ddclient.conf, then falls back to in-built defaults.

Support

If you need extra help, want to report a bug, or submit a feature request, create a GitHub issue. Before posting, check it is not a duplicate and the problem is present on the latest version of ddclient.

If you want to contribute code to ddclient, raise a pull request on GitHub.