Compare commits
No commits in common. "8256e7920a26d3e40e77ac056a5591f7b3a4127d" and "b6ce3ec7e332bdd2260d7963c6ae81425f15600b" have entirely different histories.
8256e7920a
...
b6ce3ec7e3
@ -7,12 +7,20 @@ let
|
|||||||
22 # ssh
|
22 # ssh
|
||||||
80 # http
|
80 # http
|
||||||
443 # https
|
443 # https
|
||||||
8448 # matrix
|
3478 # turn
|
||||||
10022 # gitea
|
10022 # gitea
|
||||||
|
40000
|
||||||
|
40001
|
||||||
|
40002
|
||||||
|
40003
|
||||||
];
|
];
|
||||||
open_udp_ports = lib.concatMapStringsSep "," (x: toString x) [
|
open_udp_ports = lib.concatMapStringsSep "," (x: toString x) [
|
||||||
1194 # wireguard
|
1194 # wireguard
|
||||||
3478 # turn
|
3478 # turn
|
||||||
|
40000
|
||||||
|
40001
|
||||||
|
40002
|
||||||
|
40003
|
||||||
];
|
];
|
||||||
in {
|
in {
|
||||||
networking = {
|
networking = {
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ pkgs, config, tmp, ... }:
|
{ pkgs, config, ... }:
|
||||||
|
|
||||||
with import ./network.nix;
|
with import ./network.nix;
|
||||||
{
|
{
|
||||||
@ -11,10 +11,7 @@ with import ./network.nix;
|
|||||||
registration_shared_secret = "runas!";
|
registration_shared_secret = "runas!";
|
||||||
dynamic_thumbnails = true;
|
dynamic_thumbnails = true;
|
||||||
enable_registration = true;
|
enable_registration = true;
|
||||||
app_service_config_files = [
|
app_service_config_files = [ "/var/lib/matrix-synapse/discord-registration.yaml" ];
|
||||||
"/var/lib/matrix-synapse/discord-registration.yaml"
|
|
||||||
"/var/lib/matrix-synapse/telegram-registration.yaml"
|
|
||||||
];
|
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
auto_join_rooms:
|
auto_join_rooms:
|
||||||
- "#infra:matrix.giugl.io"
|
- "#infra:matrix.giugl.io"
|
||||||
@ -82,7 +79,7 @@ with import ./network.nix;
|
|||||||
enableACME = true;
|
enableACME = true;
|
||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
|
|
||||||
root = pkgs.unstable.element-web.override {
|
root = pkgs.element-web.override {
|
||||||
conf = {
|
conf = {
|
||||||
default_server_config."m.homeserver" = {
|
default_server_config."m.homeserver" = {
|
||||||
"base_url" = "https://${matrixdomain}";
|
"base_url" = "https://${matrixdomain}";
|
||||||
@ -93,7 +90,6 @@ with import ./network.nix;
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# discord bridge
|
|
||||||
matrix-appservice-discord = {
|
matrix-appservice-discord = {
|
||||||
enable = true;
|
enable = true;
|
||||||
environmentFile = /secrets/matrix-appservice-discord/tokens.env;
|
environmentFile = /secrets/matrix-appservice-discord/tokens.env;
|
||||||
@ -107,56 +103,8 @@ with import ./network.nix;
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# telegram bridge
|
|
||||||
|
|
||||||
mautrix-telegram = {
|
|
||||||
enable = true;
|
|
||||||
environmentFile = /secrets/mautrix-telegram/mautrix-telegram.env;
|
|
||||||
|
|
||||||
settings = {
|
|
||||||
homeserver = {
|
|
||||||
address = "https://${matrixdomain}";
|
|
||||||
domain = "${matrixdomain}";
|
|
||||||
};
|
|
||||||
|
|
||||||
appservice = {
|
|
||||||
provisioning.enabled = false;
|
|
||||||
id = "telegram";
|
|
||||||
};
|
|
||||||
|
|
||||||
bridge = {
|
|
||||||
permissions = {
|
|
||||||
"@pepe:${matrixdomain}" = "admin";
|
|
||||||
"${matrixdomain}" = "puppeting";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Animated stickers conversion requires additional packages in the
|
|
||||||
# service's path.
|
|
||||||
# If this isn't a fresh installation, clearing the bridge's uploaded
|
|
||||||
# file cache might be necessary (make a database backup first!):
|
|
||||||
# delete from telegram_file where \
|
|
||||||
# mime_type in ('application/gzip', 'application/octet-stream')
|
|
||||||
animated_sticker = {
|
|
||||||
target = "gif";
|
|
||||||
args = {
|
|
||||||
width = 256;
|
|
||||||
height = 256;
|
|
||||||
fps = 30; # only for webm
|
|
||||||
background = "020202"; # only for gif, transparency not supported
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.services.mautrix-telegram.path = with pkgs; [
|
|
||||||
lottieconverter # for animated stickers conversion, unfree package
|
|
||||||
ffmpeg # if converting animated stickers to webm (very slow!)
|
|
||||||
];
|
|
||||||
|
|
||||||
networking.extraHosts = ''
|
networking.extraHosts = ''
|
||||||
127.0.0.1 ${matrixdomain} ${matrixwebdomain}
|
127.0.0.1 ${matrixdomain} ${matrixwebdomain}
|
||||||
${architect-lan} ${matrixdomain} ${matrixwebdomain}
|
${architect-lan} ${matrixdomain} ${matrixwebdomain}
|
||||||
|
@ -35,8 +35,6 @@ rec {
|
|||||||
germano-wg = "10.3.0.19";
|
germano-wg = "10.3.0.19";
|
||||||
flavio-wg = "10.3.0.20";
|
flavio-wg = "10.3.0.20";
|
||||||
tommy-wg = "10.3.0.21";
|
tommy-wg = "10.3.0.21";
|
||||||
alain-wg = "10.3.0.22";
|
|
||||||
dima-wg = "10.3.0.23";
|
|
||||||
eleonora-wg = "10.3.0.100";
|
eleonora-wg = "10.3.0.100";
|
||||||
broccolino-wg = "10.3.0.200";
|
broccolino-wg = "10.3.0.200";
|
||||||
hotpottino-wg = "10.3.0.201";
|
hotpottino-wg = "10.3.0.201";
|
||||||
|
@ -12,8 +12,6 @@ with import ./network.nix;
|
|||||||
enable = true;
|
enable = true;
|
||||||
hostName = "${nextclouddomain}";
|
hostName = "${nextclouddomain}";
|
||||||
https = true;
|
https = true;
|
||||||
package = pkgs.unstable.nextcloud22;
|
|
||||||
|
|
||||||
caching.redis = true;
|
caching.redis = true;
|
||||||
|
|
||||||
autoUpdateApps.enable = true;
|
autoUpdateApps.enable = true;
|
||||||
|
@ -1,22 +1,6 @@
|
|||||||
{ pkgs, ...}:
|
|
||||||
|
|
||||||
with import ./network.nix;
|
with import ./network.nix;
|
||||||
{
|
{
|
||||||
services.plex = {
|
services.plex.enable = true;
|
||||||
enable = true;
|
|
||||||
package = pkgs.plex.overrideAttrs (x: let
|
|
||||||
# see https://www.plex.tv/media-server-downloads/ for 64bit rpm
|
|
||||||
version = "1.24.1.4931-1a38e63c6";
|
|
||||||
sha1 = "7d0751f7efaa7b5fc9ac2a3cdb130712db6b6d89";
|
|
||||||
in {
|
|
||||||
name = "plex-${version}";
|
|
||||||
src = pkgs.fetchurl {
|
|
||||||
url = "https://downloads.plex.tv/plex-media-server-new/${version}/debian/plexmediaserver_${version}_amd64.deb";
|
|
||||||
inherit sha1;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
services.nginx = {
|
services.nginx = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -165,18 +165,6 @@ with import ./network.nix;
|
|||||||
allowedIPs = [tommy-wg];
|
allowedIPs = [tommy-wg];
|
||||||
publicKey = "tytknU7wql1d0A2provX3RP7CNcEIajfgBJKoSyVLgo=";
|
publicKey = "tytknU7wql1d0A2provX3RP7CNcEIajfgBJKoSyVLgo=";
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
|
||||||
# alain
|
|
||||||
allowedIPs = [alain-wg];
|
|
||||||
publicKey = "/o2msFJoUL4yovcIQJTU8c1faFtekrjSBBWJABouWno=";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
# dima
|
|
||||||
allowedIPs = [dima-wg];
|
|
||||||
publicKey = "svzWYIZ6v+cLCp/emGG7mx2YpBJqw2fqjVuHZy7b6H0=";
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user