Skip to content

Commit

Permalink
dns: add HTTPS record to enable HTTP3 without Alt-Svc step
Browse files Browse the repository at this point in the history
  • Loading branch information
xddxdd committed Jan 5, 2025
1 parent 8ef650e commit a4f58b4
Show file tree
Hide file tree
Showing 7 changed files with 56 additions and 0 deletions.
14 changes: 14 additions & 0 deletions dns/core/record-handlers.nix
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,13 @@ in
args.digesttype
args.digest
];
HTTPS =
args:
record "HTTPS" args [
args.priority
args.target
args.modifiers
];
IGNORE = args: record "IGNORE" args [ args.type ];
MX =
args:
Expand All @@ -72,6 +79,13 @@ in
args.type
args.value
];
SVCB =
args:
record "SVCB" args [
args.priority
args.target
args.modifiers
];
TLSA =
args:
record "TLSA" args [
Expand Down
7 changes: 7 additions & 0 deletions dns/domains/56631131.xyz.nix
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@
target = "hetzner-de";
ttl = "1h";
}
{
recordType = "HTTPS";
name = "@";
priority = 1;
target = ".";
modifiers = "alpn=h3,h2";
}
{
recordType = "CNAME";
name = "www";
Expand Down
7 changes: 7 additions & 0 deletions dns/domains/lantian.best.nix
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@
target = config.common.records.GeoDNSTarget;
ttl = "10m";
}
{
recordType = "HTTPS";
name = "@";
priority = 1;
target = ".";
modifiers = "alpn=h3,h2";
}
{
recordType = "CNAME";
name = "www";
Expand Down
7 changes: 7 additions & 0 deletions dns/domains/lantian.pub.nix
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,13 @@ in
filter = _n: v: (v.hasTag "server") && (v.hasTag "public-facing");
healthcheck = "lantian.pub";
}
{
recordType = "HTTPS";
name = "@";
priority = 1;
target = ".";
modifiers = "alpn=h3,h2";
}
{
recordType = "CNAME";
name = "www";
Expand Down
7 changes: 7 additions & 0 deletions dns/domains/ltn.pw.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,13 @@
target = "terrahost";
ttl = "10m";
}
{
recordType = "HTTPS";
name = "@";
priority = 1;
target = ".";
modifiers = "alpn=h3,h2";
}
{
recordType = "CNAME";
name = "pb.${domain}.";
Expand Down
7 changes: 7 additions & 0 deletions dns/domains/xuyh0120.com.nix
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@
target = config.common.records.GeoDNSTarget;
ttl = "10m";
}
{
recordType = "HTTPS";
name = "@";
priority = 1;
target = ".";
modifiers = "alpn=h3,h2";
}
{
recordType = "CNAME";
name = "www";
Expand Down
7 changes: 7 additions & 0 deletions dns/domains/xuyh0120.win.nix
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,13 @@ in
target = "lantian.pub.";
ttl = "5m";
}
{
recordType = "HTTPS";
name = "@";
priority = 1;
target = ".";
modifiers = "alpn=h3,h2";
}
{
recordType = "CNAME";
name = "www";
Expand Down

0 comments on commit a4f58b4

Please sign in to comment.