From e1fbaa4490c79c0358b42088fe62b783d8885753 Mon Sep 17 00:00:00 2001 From: Proesmans Bert Date: Mon, 6 Apr 2026 16:20:00 +0200 Subject: [PATCH] nixos/caddy: Fix string conversion for http and https ports Explicitly convert the port option (number type) to a string into the caddyfile. --- nixos/modules/services/web-servers/caddy/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nixos/modules/services/web-servers/caddy/default.nix b/nixos/modules/services/web-servers/caddy/default.nix index 8d60ab71771e..2ff45efd4e43 100644 --- a/nixos/modules/services/web-servers/caddy/default.nix +++ b/nixos/modules/services/web-servers/caddy/default.nix @@ -435,13 +435,13 @@ in null options.services.caddy.httpPort.default ] - ) "http_port ${cfg.httpPort}"} + ) "http_port ${toString cfg.httpPort}"} ${optionalString ( !elem cfg.httpsPort [ null options.services.caddy.httpsPort.default ] - ) "https_port ${cfg.httpsPort}"} + ) "https_port ${toString cfg.httpsPort}"} log { ${cfg.logFormat} }