Compare commits
2 Commits
f4a0e2a862
...
f46ad8a2f3
| Author | SHA1 | Date | |
|---|---|---|---|
|
f46ad8a2f3
|
|||
|
c14a3682ff
|
@@ -18,52 +18,31 @@
|
|||||||
server_name = "imxyy.top";
|
server_name = "imxyy.top";
|
||||||
allow_registration = true;
|
allow_registration = true;
|
||||||
registration_token_file = config.sops.secrets.tuwunel-reg-token.path;
|
registration_token_file = config.sops.secrets.tuwunel-reg-token.path;
|
||||||
|
well_known = {
|
||||||
|
server = "matrix.imxyy.top:443";
|
||||||
|
client = "https://matrix.imxyy.top";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
services.caddy.virtualHosts."imxyy.top" = {
|
services.caddy.virtualHosts."imxyy.top" = {
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
handle /.well-known/matrix/client {
|
handle /.well-known/matrix/server {
|
||||||
header Content-Type application/json
|
header Content-Type application/json
|
||||||
header "Access-Control-Allow-Origin" "*"
|
header "Access-Control-Allow-Origin" "*"
|
||||||
|
|
||||||
respond `{"m.homeserver": {"base_url": "https://matrix.imxyy.top"}}` 200
|
respond `{"m.server": "matrix.imxyy.top:443"}` 200
|
||||||
}
|
}
|
||||||
'';
|
|
||||||
};
|
|
||||||
services.caddy.virtualHosts."imxyy.top:8448" = {
|
|
||||||
extraConfig = ''
|
|
||||||
reverse_proxy :8094
|
|
||||||
|
|
||||||
handle /.well-known/matrix/client {
|
handle /.well-known/matrix/client {
|
||||||
header Content-Type application/json
|
header Content-Type application/json
|
||||||
header "Access-Control-Allow-Origin" "*"
|
header "Access-Control-Allow-Origin" "*"
|
||||||
|
|
||||||
respond `{"m.homeserver": {"base_url": "https://matrix.imxyy.top"}}` 200
|
respond `{"m.homeserver": {"base_url": "https://matrix.imxyy.top/"}}` 200
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
services.caddy.virtualHosts."matrix.imxyy.top" = {
|
services.caddy.virtualHosts."matrix.imxyy.top" = {
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
reverse_proxy :8094
|
reverse_proxy :8094
|
||||||
|
|
||||||
handle /.well-known/matrix/client {
|
|
||||||
header Content-Type application/json
|
|
||||||
header "Access-Control-Allow-Origin" "*"
|
|
||||||
|
|
||||||
respond `{"m.homeserver": {"base_url": "https://matrix.imxyy.top"}}` 200
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
services.caddy.virtualHosts."matrix.imxyy.top:8448" = {
|
|
||||||
extraConfig = ''
|
|
||||||
reverse_proxy :8094
|
|
||||||
|
|
||||||
handle /.well-known/matrix/client {
|
|
||||||
header Content-Type application/json
|
|
||||||
header "Access-Control-Allow-Origin" "*"
|
|
||||||
|
|
||||||
respond `{"m.homeserver": {"base_url": "https://matrix.imxyy.top"}}` 200
|
|
||||||
}
|
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
{ lib, pkgs, ... }:
|
{ lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
/*
|
systemd.services."fabric1.20.6" = {
|
||||||
systemd.services."fabric1.20.6" = {
|
description = "fabric 1.20.6 minecraft server";
|
||||||
description = "fabric 1.20.6 minecraft server";
|
wantedBy = [ "multi-user.target" ];
|
||||||
wantedBy = [ "multi-user.target" ];
|
after = [ "network.target" ];
|
||||||
after = [ "network.target" ];
|
serviceConfig = {
|
||||||
serviceConfig = {
|
WorkingDirectory = "/opt/minecraft/fabric1.20.6";
|
||||||
WorkingDirectory = "/opt/minecraft/fabric1.20.6";
|
ExecStart = "${lib.getExe' pkgs.openjdk21 "java"} -Xms1G -Xmx5G -jar fabric-server-mc.1.20.6-loader.0.15.11-launcher.1.0.1.jar";
|
||||||
ExecStart = "${lib.getExe' pkgs.openjdk21 "java"} -Xms1G -Xmx5G -jar fabric-server-mc.1.20.6-loader.0.15.11-launcher.1.0.1.jar";
|
Restart = "always";
|
||||||
Restart = "always";
|
RestartSec = 120;
|
||||||
RestartSec = 120;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
*/
|
};
|
||||||
|
|
||||||
my.persist = {
|
my.persist = {
|
||||||
nixosDirs = [
|
nixosDirs = [
|
||||||
"/opt/minecraft"
|
"/opt/minecraft"
|
||||||
|
|||||||
@@ -405,13 +405,6 @@
|
|||||||
localPort = 443;
|
localPort = 443;
|
||||||
customDomains = [ "matrix.imxyy.top" ];
|
customDomains = [ "matrix.imxyy.top" ];
|
||||||
}
|
}
|
||||||
{
|
|
||||||
name = "matrix-fed";
|
|
||||||
type = "tcp";
|
|
||||||
localIP = "127.0.0.1";
|
|
||||||
localPort = 8448;
|
|
||||||
remotePort = 8448;
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
{
|
||||||
name = "immich-http";
|
name = "immich-http";
|
||||||
@@ -442,14 +435,6 @@
|
|||||||
localPort = 443;
|
localPort = 443;
|
||||||
customDomains = [ "memo.imxyy.top" ];
|
customDomains = [ "memo.imxyy.top" ];
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
|
||||||
name = "minecraft";
|
|
||||||
type = "tcp";
|
|
||||||
localIP = "127.0.0.1";
|
|
||||||
localPort = 25565;
|
|
||||||
remotePort = 25565;
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user