summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlassulus <lassulus@lassul.us>2021-10-31 12:35:16 +0100
committerlassulus <lassulus@lassul.us>2021-10-31 12:35:16 +0100
commit9fd58eb16278aa098422b9e28299b374f98e0a9e (patch)
tree9df42ec6ce13906158e70541ffa705da49e0bb26
parente1fdb4728c2a886435c16dd4323a26d9f4c5ab16 (diff)
l codimd: move to pad.lassul.us
-rw-r--r--krebs/3modules/lass/default.nix1
-rw-r--r--lass/2configs/codimd.nix10
2 files changed, 10 insertions, 1 deletions
diff --git a/krebs/3modules/lass/default.nix b/krebs/3modules/lass/default.nix
index 95669c243..e96b4d8be 100644
--- a/krebs/3modules/lass/default.nix
+++ b/krebs/3modules/lass/default.nix
@@ -37,6 +37,7 @@ in {
default._domainkey 60 IN TXT "k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDUv3DMndFellqu208feABEzT/PskOfTSdJCOF/HELBR0PHnbBeRoeHEm9XAcOe/Mz2t/ysgZ6JFXeFxCtoM5fG20brUMRzsVRxb9Ur5cEvOYuuRrbChYcKa+fopu8pYrlrqXD3miHISoy6ErukIYCRpXWUJHi1TlNQhLWFYqAaywIDAQAB"
cache 60 IN A ${config.krebs.hosts.prism.nets.internet.ip4.addr}
cgit 60 IN A ${config.krebs.hosts.prism.nets.internet.ip4.addr}
+ pad 60 IN A ${config.krebs.hosts.prism.nets.internet.ip4.addr}
codi 60 IN A ${config.krebs.hosts.prism.nets.internet.ip4.addr}
go 60 IN A ${config.krebs.hosts.prism.nets.internet.ip4.addr}
io 60 IN NS ions.lassul.us.
diff --git a/lass/2configs/codimd.nix b/lass/2configs/codimd.nix
index 070781a31..271dcfca4 100644
--- a/lass/2configs/codimd.nix
+++ b/lass/2configs/codimd.nix
@@ -1,8 +1,16 @@
{ config, pkgs, lib, ... }:
with import <stockholm/lib>;
let
- domain = "codi.lassul.us";
+ domain = "pad.lassul.us";
in {
+
+ # redirect legacy domain to new one
+ services.nginx.virtualHosts."codi.lassul.us" = {
+ enableACME = true;
+ addSSL = true;
+ locations."/".return = "301 https://${domain}\$request_uri";
+ };
+
services.nginx.virtualHosts.${domain} = {
enableACME = true;
forceSSL = true;