From 406e37fde1d7f905ccb377f4ab9a857b750e372e Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Mon, 20 Jul 2020 00:38:40 +0100 Subject: feat(whitby): Deploy todo.tvl.fyi page with //web/todolist Note that this is not yet updated automatically, so the page will be stale until somebody rebuilds whitby. Change-Id: I91f4b03c9309aed289df055fac292a214dca7668 Reviewed-on: https://cl.tvl.fyi/c/depot/+/1297 Reviewed-by: Alyssa Ross Tested-by: BuildkiteCI --- ops/nixos/whitby/default.nix | 1 + ops/nixos/www/todo.tvl.fyi.nix | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 ops/nixos/www/todo.tvl.fyi.nix diff --git a/ops/nixos/whitby/default.nix b/ops/nixos/whitby/default.nix index e42bdc864f37..85f47cbccdef 100644 --- a/ops/nixos/whitby/default.nix +++ b/ops/nixos/whitby/default.nix @@ -26,6 +26,7 @@ in lib.fix(self: { "${depot.depotPath}/ops/nixos/www/code.tvl.fyi.nix" "${depot.depotPath}/ops/nixos/www/cs.tvl.fyi.nix" "${depot.depotPath}/ops/nixos/www/login.tvl.fyi.nix" + "${depot.depotPath}/ops/nixos/www/todo.tvl.fyi.nix" "${depot.depotPath}/ops/nixos/www/tvl.fyi.nix" "${depot.third_party.nixpkgsSrc}/nixos/modules/services/web-apps/gerrit.nix" ]; diff --git a/ops/nixos/www/todo.tvl.fyi.nix b/ops/nixos/www/todo.tvl.fyi.nix new file mode 100644 index 000000000000..0820d136d295 --- /dev/null +++ b/ops/nixos/www/todo.tvl.fyi.nix @@ -0,0 +1,24 @@ +{ config, ... }: + +{ + imports = [ + ./base.nix + ]; + + config = { + services.nginx.virtualHosts."todo.tvl.fyi" = { + serverName = "todo.tvl.fyi"; + root = config.depot.web.todolist; + enableACME = true; + forceSSL = true; + + extraConfig = '' + add_header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload" always; + + location ~* \.(webp|woff2)$ { + add_header Cache-Control "public, max-age=31536000"; + } + ''; + }; + }; +} -- cgit 1.4.1