Matrix Docker Ansible eploy
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

4.5 KiB

Setting up Dynamic DNS (optional)

The playbook can configure Dynamic DNS with ddclient⁠ for you. It is a Perl client used to update dynamic DNS entries for accounts on Dynamic DNS Network Service Provider.

Most cloud providers / ISPs will charge you extra for a static IP address. If you’re not hosting a highly reliable homeserver you can workaround this via dynamic DNS.

For details about configuring the Ansible role for ddclient, you can check them via:

Prerequisite

You’ll need to authenticate with your DNS provider somehow, in most cases this is simply a username and password but can differ from provider to provider. Please consult with your providers documentation and the upstream ddclient documentation to determine what you’ll need to provide to authenticate.

Adjusting the playbook configuration

To enable dynamic DNS, add the following configuration to your inventory/host_vars/matrix.example.com/vars.yml file:

ddclient_enabled: true

ddclient_domain_configurations:
  - provider: example.net
    protocol: dyndns2
    username: YOUR_USERNAME_HERE
    password: YOUR_PASSWORD_HERE
    domain: "{{ matrix_domain }}"

Keep in mind that certain providers may require a different configuration of the ddclient_domain_configurations variable, for provider specific examples see the upstream documentation.

Configuring the endpoint to obtain IP address (optional)

The playbook sets the default endpoint for obtaining the IP address to https://cloudflare.com/cdn-cgi/trace. You can replace it by specifying yours to ddclient_web and ddclient_web_skip if necessary.

Refer to this section for more information.

Extending the configuration

There are some additional things you may wish to configure about the component.

Take a look at:

  • roles/galaxy/ddclient/defaults/main.yml for some variables that you can customize via your vars.yml file

Installing

After configuring the playbook, run it with playbook tags as below:

ansible-playbook -i inventory/hosts setup.yml --tags=setup-all,start

The shortcut commands with the just program are also available: just install-all or just setup-all

just install-all is useful for maintaining your setup quickly (2x-5x faster than just setup-all) when its components remain unchanged. If you adjust your vars.yml to remove other components, you’d need to run just setup-all, or these components will still remain installed. Note these shortcuts run the ensure-matrix-users-created tag too.

Additional Reading

Additional resources:

Troubleshooting

See this section on the role’s documentation for details.