Update dingserver
This commit is contained in:
@@ -1,39 +0,0 @@
|
|||||||
{pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
services.mautrix-facebook = {
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
# file containing the appservice and telegram tokens
|
|
||||||
#environmentFile = /etc/secrets/mautrix-telegram.env;
|
|
||||||
|
|
||||||
# The appservice is pre-configured to use SQLite by default.
|
|
||||||
# It's also possible to use PostgreSQL.
|
|
||||||
settings = {
|
|
||||||
homeserver = {
|
|
||||||
address = "http://localhost:8008";
|
|
||||||
domain = "broccoli.town";
|
|
||||||
};
|
|
||||||
appservice = {
|
|
||||||
address = "https://localhost:29319";
|
|
||||||
bot_username = "messenger_bot";
|
|
||||||
database = "sqlite:///var/lib/mautrix/bot.db";
|
|
||||||
port = 29319;
|
|
||||||
as_token = "NwNtnSTUaIIxf8DIew1XMYyktrbckiMp8iwcXUGkHq28tYVc99A-IL2swBR7WFtl";
|
|
||||||
hs_token = "QAuD0k9I3QCfEfhlnWbqBFGOTJz-fFdesnzZOovJxdfGVMDCkdFEb6Zvu5eGAIZi";
|
|
||||||
};
|
|
||||||
bridge = {
|
|
||||||
encryption = {
|
|
||||||
allow = true;
|
|
||||||
default = true;
|
|
||||||
};
|
|
||||||
username_template = "facebook_{userid}";
|
|
||||||
permissions = {
|
|
||||||
"*" = "relay";
|
|
||||||
"broccoli.town" = "user";
|
|
||||||
"@dung:broccoli.town" = "admin";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -42,6 +42,7 @@
|
|||||||
"danielpatterson.dev" = {
|
"danielpatterson.dev" = {
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
root * /srv/site/danielpatterson.dev
|
root * /srv/site/danielpatterson.dev
|
||||||
|
encode zstd gzip
|
||||||
file_server
|
file_server
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -4,8 +4,9 @@
|
|||||||
imports =
|
imports =
|
||||||
[ # Include the results of the hardware scan.
|
[ # Include the results of the hardware scan.
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
./synapse.nix
|
|
||||||
./caddy.nix
|
./caddy.nix
|
||||||
|
./synapse.nix
|
||||||
|
./syncthing.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
# Use the GRUB 2 boot loader.
|
# Use the GRUB 2 boot loader.
|
||||||
@@ -26,12 +27,13 @@
|
|||||||
|
|
||||||
users.users.daniel = {
|
users.users.daniel = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
extraGroups = [ "wheel" ]; # Enable ‘sudo’ for the user.
|
extraGroups = [ "wheel" "syncthing" ]; # Enable ‘sudo’ for the user.
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
curl
|
curl
|
||||||
git
|
git
|
||||||
|
helix
|
||||||
kitty
|
kitty
|
||||||
lazygit
|
lazygit
|
||||||
wget
|
wget
|
||||||
|
|||||||
@@ -6,23 +6,24 @@ in {
|
|||||||
|
|
||||||
services.matrix-synapse = {
|
services.matrix-synapse = {
|
||||||
enable = true;
|
enable = true;
|
||||||
server_name = "broccoli.town";
|
settings = {
|
||||||
database_type = "sqlite3";
|
server_name = "broccoli.town";
|
||||||
max_upload_size = "50M";
|
database.name = "sqlite3";
|
||||||
listeners = [
|
max_upload_size = "50M";
|
||||||
{
|
listeners = [
|
||||||
port = 8008;
|
{
|
||||||
bind_address = "::1";
|
port = 8008;
|
||||||
type = "http";
|
type = "http";
|
||||||
tls = false;
|
tls = false;
|
||||||
x_forwarded = true;
|
x_forwarded = true;
|
||||||
resources = [
|
resources = [
|
||||||
{
|
{
|
||||||
names = [ "client" "federation" ];
|
names = [ "client" "federation" ];
|
||||||
compress = false;
|
compress = false;
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
6
hosts/dingserver/syncthing.nix
Normal file
6
hosts/dingserver/syncthing.nix
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
{
|
||||||
|
services.syncthing = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user