about summary refs log tree commit diff
path: root/nixos
diff options
context:
space:
mode:
authorBas van Dijk <v.dijk.bas@gmail.com>2017-10-31 17:31:02 +0100
committerBas van Dijk <v.dijk.bas@gmail.com>2017-10-31 17:33:54 +0100
commit527781ebc4137d9e6cda6dd21ab0dd776f8582d5 (patch)
tree63e9872ee154b7733775c30539b00d90b2cc8b9f /nixos
parentfe9cefa7e4ed4da1a0d1d9777bf0f7145fff22e3 (diff)
downloadnixlib-527781ebc4137d9e6cda6dd21ab0dd776f8582d5.tar
nixlib-527781ebc4137d9e6cda6dd21ab0dd776f8582d5.tar.gz
nixlib-527781ebc4137d9e6cda6dd21ab0dd776f8582d5.tar.bz2
nixlib-527781ebc4137d9e6cda6dd21ab0dd776f8582d5.tar.lz
nixlib-527781ebc4137d9e6cda6dd21ab0dd776f8582d5.tar.xz
nixlib-527781ebc4137d9e6cda6dd21ab0dd776f8582d5.tar.zst
nixlib-527781ebc4137d9e6cda6dd21ab0dd776f8582d5.zip
apache-httpd: fix nix evaluation error
This only sets the timezone when it's not null to prevent:

  error: cannot coerce null to a string, at
  nixpkgs/nixos/modules/services/web-servers/apache-httpd/default.nix:676:7
Diffstat (limited to 'nixos')
-rw-r--r--nixos/modules/services/web-servers/apache-httpd/default.nix1
1 files changed, 1 insertions, 0 deletions
diff --git a/nixos/modules/services/web-servers/apache-httpd/default.nix b/nixos/modules/services/web-servers/apache-httpd/default.nix
index 1c3c7835d961..f9f2511f45dc 100644
--- a/nixos/modules/services/web-servers/apache-httpd/default.nix
+++ b/nixos/modules/services/web-servers/apache-httpd/default.nix
@@ -676,6 +676,7 @@ in
       ''
         ; Needed for PHP's mail() function.
         sendmail_path = sendmail -t -i
+      '' + optionalString (!isNull config.time.timeZone) ''
 
         ; Apparently PHP doesn't use $TZ.
         date.timezone = "${config.time.timeZone}"