More service changes

This commit is contained in:
Jimbo 2024-11-13 06:23:13 -05:00
parent e43f8c27a1
commit 54855a0d33
7 changed files with 31 additions and 43 deletions

View file

@ -3,7 +3,7 @@
services.fail2ban = {
enable = true;
maxretry = 5;
bantime = "5m";
bantime = "10m";
};
environment.persistence."/persist".directories = [ "/var/lib/fail2ban" ];

View file

@ -12,7 +12,6 @@
"*.${config.domains.jim1}"
"sv.${config.domains.jim1}"
"git.${config.domains.jim1}"
"rtmp.${config.domains.jim1}"
"turn.${config.domains.jim1}"
"dew.${config.domains.jim1}"
"john.${config.domains.jim1}"

View file

@ -32,6 +32,5 @@
};
};
# Allow Forgejo's SSH to work
networking.firewall.allowedTCPPorts = [ 2299 ];
}

View file

@ -1,35 +1,31 @@
{ config, ... }:
{
services.nginx.virtualHosts = {
"${config.domains.jim1}" = {
enableACME = true;
addSSL = true;
root = "/var/www/Jimbo-Landing-Page";
locations = {
"/.well-known/matrix/client" = {
extraConfig = ''
default_type application/json;
return 200 '
{
"m.homeserver": {
"base_url": "https://matrix.${config.domains.jim1}"
},
"m.identity_server": {
"base_url": "https://matrix.org"
},
"org.matrix.msc3575.proxy": {
"url": "https://matrix.${config.domains.jim1}"
}
}';
'';
};
"/.well-known/matrix/server" = {
extraConfig = ''
default_type application/json;
return 200 '{"m.server": "matrix.${config.domains.jim1}:443"}';
'';
};
};
services.nginx.virtualHosts."${config.domains.jim1}" = {
enableACME = true;
addSSL = true;
root = "/var/www/Jimbo-Landing-Page";
locations = {
"/.well-known/matrix/client".extraConfig = ''
default_type application/json;
return 200 '
{
"m.homeserver": {
"base_url": "https://matrix.${config.domains.jim1}"
},
"m.identity_server": {
"base_url": "https://matrix.org"
},
"org.matrix.msc3575.proxy": {
"url": "https://matrix.${config.domains.jim1}"
}
}
';
'';
"/.well-known/matrix/server".extraConfig = ''
default_type application/json;
return 200 '{ "m.server": "matrix.${config.domains.jim1}:443" }';
'';
};
};
}

View file

@ -1,4 +0,0 @@
{ ... }:
{
services.snowflake-proxy.enable = true;
}

View file

@ -3,11 +3,9 @@
imports = [ ./nginx ];
nixpkgs.config.element-web.conf = {
default_server_config = {
"m.homeserver" = {
base_url = "https://matrix.${config.domains.jim1}";
server_name = "matrix.${config.domains.jim1}";
};
default_server_config."m.homeserver" = {
base_url = "https://matrix.${config.domains.jim1}";
server_name = "matrix.${config.domains.jim1}";
};
branding = {
#welcome_background_url = "https://staging.${config.domains.jim1}/images/backgrounds/template-background.png";

View file

@ -7,7 +7,7 @@
settings = {
APP_NAME = ''"Jimbo's Pixelfed"'';
INSTANCE_DESCRIPTION = ''"The Jimbosfiles Pixelfed Instance"'';
INSTANCE_CONTACT_EMAIL = "jimbo@${config.domains.jim2}";
INSTANCE_CONTACT_EMAIL = "contact@${config.domains.jim2}";
OPEN_REGISTRATION = true;
APP_LOCALE = "en";
INSTANCE_DISCOVER_PUBLIC = true;