From 826530e5bb12d71bb4b93e9c918ac5e7bbe82495 Mon Sep 17 00:00:00 2001 From: coolneng Date: Tue, 30 Mar 2021 14:01:53 +0200 Subject: [PATCH] Configure ddclient with duckdns as a provider --- modules/networking.nix | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/modules/networking.nix b/modules/networking.nix index cc98739..16249e7 100644 --- a/modules/networking.nix +++ b/modules/networking.nix @@ -1,6 +1,8 @@ { config, lib, pkgs, ... }: -{ +let password = builtins.readFile /var/keys/ddclient; + +in { # Assign a static IP networking = { hostName = "unit"; @@ -31,6 +33,15 @@ }; }; + # Dynamic DNS configuration + services.ddclient = { + enable = true; + quiet = true; + protocol = "duckdns"; + domains = [ "coace.duckdns.org" ]; + inherit password; + }; + # Firewall configuration networking.firewall = { allowedTCPPorts = [