This commit is contained in:
2023-08-01 13:21:43 -04:00
parent 66cca6bc2f
commit b65bc1696b
2 changed files with 59 additions and 26 deletions

30
flake.lock generated
View File

@@ -4,15 +4,14 @@
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
], ]
"utils": "utils"
}, },
"locked": { "locked": {
"lastModified": 1679758258, "lastModified": 1690887397,
"narHash": "sha256-/fsleSIKfnCCzrn4MIAEDTCKeCe+ZxXEPrKykAI5q08=", "narHash": "sha256-ckasuN7MgAiDgLkUo1IdEq8FEKymcUWKzmY6/R9KOOo=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "d80bf24dab1c1abb3c36e6e28cd30d27599a9620", "rev": "4542db605602898fe0c431e19f01e1af2865dae8",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -23,11 +22,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1679705136, "lastModified": 1690881714,
"narHash": "sha256-MDlZUR7wJ3PlPtqwwoGQr3euNOe0vdSSteVVOef7tBY=", "narHash": "sha256-h/nXluEqdiQHs1oSgkOOWF+j8gcJMWhwnZ9PFabN6q0=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "8f40f2f90b9c9032d1b824442cfbbe0dbabd0dbd", "rev": "9e1960bc196baf6881340d53dccb203a951745a2",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -41,21 +40,6 @@
"home-manager": "home-manager", "home-manager": "home-manager",
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
} }
},
"utils": {
"locked": {
"lastModified": 1676283394,
"narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",

View File

@@ -27,6 +27,14 @@
fonts.fontconfig.enable = true; fonts.fontconfig.enable = true;
home.packages = with pkgs; [ fira-code jetbrains-mono iosevka monoid recursive ]; home.packages = with pkgs; [ fira-code jetbrains-mono iosevka monoid recursive ];
systemd.user.services.mpris-proxy = {
Unit.Description = "Mpris proxy";
Unit.After = [ "network.target" "sound.target" ];
Service.ExecStart = "${pkgs.bluez}/bin/mpris-proxy";
Install.WantedBy = [ "default.target" ];
};
programs.foot = { programs.foot = {
enable = true; enable = true;
settings = { settings = {
@@ -231,7 +239,7 @@
#fonts.fonts = with pkgs; [ fira-code jetbrains-mono iosevka ]; #fonts.fonts = with pkgs; [ fira-code jetbrains-mono iosevka ];
# testing # testing
services.jellyfin.enable = false; #services.jellyfin.enable = false;
services.pipewire = { services.pipewire = {
enable = true; enable = true;
alsa.enable = true; alsa.enable = true;
@@ -244,6 +252,8 @@
extraPortals = [pkgs.xdg-desktop-portal-gtk ]; extraPortals = [pkgs.xdg-desktop-portal-gtk ];
gtkUsePortal = true; gtkUsePortal = true;
}; };
hardware.bluetooth.enable = true;
services.blueman.enable = true; services.blueman.enable = true;
services.printing.enable = true; services.printing.enable = true;
@@ -339,7 +349,7 @@
modules = [ modules = [
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager
homeManagerSharedModule homeManagerSharedModule
({ config, lib, pkgs, modulesPath, ... }@innerArgs: (lib.recursiveUpdate (commonConfigFunc innerArgs [ pkgs.light ]) { ({ config, lib, pkgs, modulesPath, ... }@innerArgs: (lib.recursiveUpdate (commonConfigFunc innerArgs [ pkgs.light pkgs.gpodder ]) {
# HARDWARE # HARDWARE
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
@@ -466,6 +476,15 @@
python-olm pycryptodome unpaddedbase64 python-olm pycryptodome unpaddedbase64
]); ]);
}); });
#lemmy-server = super.lemmy-server.overrideAttrs (old: {
# patches = (old.patches or []) ++ [(super.fetchpatch {
# name = "fix-db-migrations.patch";
# url = "https://gist.githubusercontent.com/matejc/9be474fa581c1a29592877ede461f1f2/raw/83886917153fcba127b43d9a94a49b3d90e635b3/fix-db-migrations.patch";
# hash = "sha256-BvoA4K9v84n60lG96j1+91e8/ERn9WlVTGk4Z6Fj4iA=";
# })];
#});
}) ]; }) ];
# Use the GRUB 2 boot loader. # Use the GRUB 2 boot loader.
@@ -606,6 +625,17 @@
httpPort = 3001; httpPort = 3001;
}; };
#systemd.services.lemmy.environment.RUST_BACKTRACE = "full";
#systemd.services.lemmy.environment.LEMMY_DATABASE_URL = pkgs.lib.mkForce "postgres:///lemmy?host=/run/postgresql&user=lemmy";
#services.lemmy = {
# enable = true;
# database.createLocally = true;
# settings = {
# hostname = "lemmy.room409.xyz";
# };
# nginx.enable = true;
#};
services.postgresql = { services.postgresql = {
enable = true; enable = true;
# postgresql user and db name in the service.matrix-synapse.databse_args setting is default # postgresql user and db name in the service.matrix-synapse.databse_args setting is default
@@ -632,6 +662,7 @@
port = 9134; port = 9134;
username = "miloignis"; username = "miloignis";
passwordFile = /var/lib/ttyd/secrets; passwordFile = /var/lib/ttyd/secrets;
clientOptions.fontFamily="Recursive";
}; };
security.acme.email = "miloignis@gmail.com"; security.acme.email = "miloignis@gmail.com";
@@ -652,6 +683,12 @@
}; };
}; };
## the rest is defined by the lemmy service
#virtualHosts."lemmy.room409.xyz" = {
# forceSSL = true;
# enableACME = true;
#};
virtualHosts."forge.room409.xyz" = { virtualHosts."forge.room409.xyz" = {
forceSSL = true; forceSSL = true;
enableACME = true; enableACME = true;
@@ -701,7 +738,7 @@
enableACME = true; enableACME = true;
root = "/var/www/faint.room409.xyz"; root = "/var/www/faint.room409.xyz";
}; };
virtualHosts."ttyd.room409.xyz" = { virtualHosts."shell.room409.xyz" = {
forceSSL = true; forceSSL = true;
enableACME = true; enableACME = true;
locations."/" = { locations."/" = {
@@ -709,6 +746,17 @@
proxyWebsockets = true; proxyWebsockets = true;
}; };
}; };
virtualHosts."drop.room409.xyz" = {
forceSSL = true;
enableACME = true;
locations."/" = {
proxyPass = "http://localhost:9009";
proxyWebsockets = true;
extraConfig = ''
client_max_body_size 500M;
'';
};
};
#virtualHosts."www.kraken-lang.org" = { #virtualHosts."www.kraken-lang.org" = {
# forceSSL = true; # forceSSL = true;
# enableACME = true; # enableACME = true;
@@ -834,6 +882,7 @@
iftop ripgrep iftop ripgrep
config.services.headscale.package config.services.headscale.package
#wireguard #wireguard
droopy
]; ];
users.extraUsers.nathan = { users.extraUsers.nathan = {
name = "nathan"; name = "nathan";