feat: zenbrowser + nas attempt through tailscale + lib cc
This commit is contained in:
parent
0a5118e815
commit
da3cf14e5e
5 changed files with 120 additions and 40 deletions
|
@ -1,4 +1,4 @@
|
||||||
{ config, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
boot.loader.systemd-boot.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
|
@ -41,7 +41,17 @@
|
||||||
nvidiaSettings = true;
|
nvidiaSettings = true;
|
||||||
package = config.boot.kernelPackages.nvidiaPackages.latest;
|
package = config.boot.kernelPackages.nvidiaPackages.latest;
|
||||||
};
|
};
|
||||||
|
services.tailscale = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
services.syncthing = {
|
||||||
|
enable = true;
|
||||||
|
openDefaultPorts = true;
|
||||||
|
settings.gui = {
|
||||||
|
user = "mrflos";
|
||||||
|
password = "VerySecurePassword";
|
||||||
|
};
|
||||||
|
};
|
||||||
services.xserver = {
|
services.xserver = {
|
||||||
enable = true;
|
enable = true;
|
||||||
videoDrivers = [
|
videoDrivers = [
|
||||||
|
@ -51,45 +61,50 @@
|
||||||
xkb.variant = "";
|
xkb.variant = "";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt/nas/music" = {
|
fileSystems."/home/mrflos/Nas-music" = {
|
||||||
device = "192.168.1.2:/volume1/music";
|
device = "diskstation.tailed460c.ts.net:/volume1/music";
|
||||||
options = [
|
options = [
|
||||||
"nfsvers=4.2"
|
#"nfsvers=4.2"
|
||||||
"x-systemd.automount"
|
"x-systemd.automount"
|
||||||
"noauto"
|
"noauto"
|
||||||
"rw"
|
#"rw"
|
||||||
"relatime"
|
#"relatime"
|
||||||
"user"
|
#"user"
|
||||||
"acl"
|
#"acl"
|
||||||
"defaults"
|
#"defaults"
|
||||||
];
|
];
|
||||||
fsType = "nfs";
|
fsType = "nfs";
|
||||||
};
|
};
|
||||||
|
|
||||||
services.rpcbind.enable = true; # needed for NFS
|
services.rpcbind.enable = true; # needed for NFS
|
||||||
systemd.mounts = [
|
#systemd.mounts = [
|
||||||
{
|
# {
|
||||||
type = "nfs";
|
# type = "nfs";
|
||||||
mountConfig = {
|
# mountConfig = {
|
||||||
Options = "defaults,acl,user,noauto,relatime,rw";
|
# Options = "defaults,acl,user,noauto,relatime,rw";
|
||||||
};
|
# };
|
||||||
what = "192.168.1.2:/volume1/music";
|
# what = "diskstation.tailed460c.ts.net:/volume1/music";
|
||||||
where = "/mnt/nas/music";
|
# where = "/mnt/nas/music";
|
||||||
}
|
# }
|
||||||
];
|
#];
|
||||||
|
|
||||||
systemd.automounts = [
|
#systemd.automounts = [
|
||||||
{
|
# {
|
||||||
wantedBy = [ "multi-user.target" ];
|
# wantedBy = [ "multi-user.target" ];
|
||||||
automountConfig = {
|
# automountConfig = {
|
||||||
TimeoutIdleSec = "600";
|
# TimeoutIdleSec = "600";
|
||||||
};
|
# };
|
||||||
where = "/mnt/nas/music";
|
# where = "/mnt/nas/music";
|
||||||
}
|
# }
|
||||||
];
|
#];
|
||||||
|
|
||||||
services.printing.enable = true;
|
services.printing.enable = true;
|
||||||
|
security.wrappers."mount.nfs" = {
|
||||||
|
setuid = true;
|
||||||
|
owner = "root";
|
||||||
|
group = "root";
|
||||||
|
source = "${pkgs.nfs-utils.out}/bin/mount.nfs";
|
||||||
|
};
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
services.pipewire = {
|
services.pipewire = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -98,6 +113,12 @@
|
||||||
pulse.enable = true;
|
pulse.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment = {
|
||||||
|
sessionVariables = {
|
||||||
|
LD_LIBRARY_PATH = "${pkgs.stdenv.cc.cc.lib}/lib";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
imports = [
|
imports = [
|
||||||
../../modules/console.nix
|
../../modules/console.nix
|
||||||
../../modules/desktop.nix
|
../../modules/desktop.nix
|
||||||
|
@ -106,14 +127,9 @@
|
||||||
../../modules/local-dev.nix
|
../../modules/local-dev.nix
|
||||||
../../modules/nixos.nix
|
../../modules/nixos.nix
|
||||||
../../modules/systemd-unfreeze.nix
|
../../modules/systemd-unfreeze.nix
|
||||||
|
../../modules/zen-browser.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
#programs.proxychains.enable = true;
|
|
||||||
#programs.proxychains.proxies.prx1.enable = true;
|
|
||||||
#programs.proxychains.proxies.prx1.type = "socks5";
|
|
||||||
#programs.proxychains.proxies.prx1.host = "127.0.0.1";
|
|
||||||
#programs.proxychains.proxies.prx1.port = 9090;
|
|
||||||
|
|
||||||
#services.ollama = {
|
#services.ollama = {
|
||||||
# enable = true;
|
# enable = true;
|
||||||
# acceleration = "cuda";
|
# acceleration = "cuda";
|
||||||
|
|
|
@ -71,6 +71,7 @@
|
||||||
# Sets up all the libraries to load
|
# Sets up all the libraries to load
|
||||||
nix-ld.libraries = with pkgs; [
|
nix-ld.libraries = with pkgs; [
|
||||||
stdenv.cc.cc
|
stdenv.cc.cc
|
||||||
|
stdenv.cc.cc.lib
|
||||||
zlib
|
zlib
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
|
@ -60,6 +60,19 @@ in
|
||||||
waybar
|
waybar
|
||||||
yarn
|
yarn
|
||||||
];
|
];
|
||||||
|
xdg = {
|
||||||
|
enable = true;
|
||||||
|
desktopEntries."zen" = {
|
||||||
|
name = "Zen Browser";
|
||||||
|
genericName = "Web Browser";
|
||||||
|
exec = "zen";
|
||||||
|
terminal = false;
|
||||||
|
mimeType = [
|
||||||
|
"text/html"
|
||||||
|
"text/xml"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
# imports = [
|
# imports = [
|
||||||
# (plasma-manager + "/modules")
|
# (plasma-manager + "/modules")
|
||||||
|
@ -104,6 +117,7 @@ in
|
||||||
};
|
};
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
EDITOR = "nvim";
|
EDITOR = "nvim";
|
||||||
|
#LD_LIBRARY_PATH = "${pkgs.stdenv.cc.cc.lib}/lib";
|
||||||
};
|
};
|
||||||
home.sessionPath = [
|
home.sessionPath = [
|
||||||
"$HOME/.local/bin"
|
"$HOME/.local/bin"
|
||||||
|
@ -238,7 +252,9 @@ in
|
||||||
mpris
|
mpris
|
||||||
sponsorblock
|
sponsorblock
|
||||||
thumbfast
|
thumbfast
|
||||||
uosc
|
#uosc
|
||||||
|
#modernx
|
||||||
|
mpv-osc-tethys
|
||||||
visualizer
|
visualizer
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -10,11 +10,11 @@
|
||||||
# enable = true;
|
# enable = true;
|
||||||
# setSocketVariable = true;
|
# setSocketVariable = true;
|
||||||
#};
|
#};
|
||||||
#libvirtd.enable = true;
|
libvirtd.enable = true;
|
||||||
#lxd.enable = true;
|
lxd.enable = true;
|
||||||
#waydroid.enable = true
|
#waydroid.enable = true
|
||||||
};
|
};
|
||||||
#programs.virt-manager.enable = true;
|
programs.virt-manager.enable = true;
|
||||||
#systemd.services.yeswikidev = {
|
#systemd.services.yeswikidev = {
|
||||||
# enable = true;
|
# enable = true;
|
||||||
# script = ''
|
# script = ''
|
||||||
|
@ -93,6 +93,8 @@
|
||||||
gcc
|
gcc
|
||||||
go
|
go
|
||||||
nixfmt-rfc-style
|
nixfmt-rfc-style
|
||||||
|
libstdcxx5
|
||||||
|
stdenv.cc.cc.lib
|
||||||
lua
|
lua
|
||||||
lua-language-server
|
lua-language-server
|
||||||
luarocks
|
luarocks
|
||||||
|
|
45
modules/zen-browser.nix
Normal file
45
modules/zen-browser.nix
Normal file
|
@ -0,0 +1,45 @@
|
||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
version = "1.8.2b";
|
||||||
|
|
||||||
|
zenbrowser = pkgs.appimageTools.wrapType2 {
|
||||||
|
name = "zen";
|
||||||
|
src = pkgs.fetchurl {
|
||||||
|
url = "https://github.com/zen-browser/desktop/releases/download/${version}/zen-x86_64.AppImage";
|
||||||
|
hash = "sha256-hZiJ8JLzLhtD1W8DAso3yBAJYhFE+nJEbQJa59AWjnU=";
|
||||||
|
};
|
||||||
|
extraInstallCommands = ''
|
||||||
|
mkdir -p $out/share/applications
|
||||||
|
cat > $out/share/applications/zenbrowser.desktop <<EOF
|
||||||
|
[Desktop Entry]
|
||||||
|
Type=Application
|
||||||
|
Name=Zen Browser
|
||||||
|
Icon=zen-browser
|
||||||
|
Exec=zen %F
|
||||||
|
Comment=Internet Browser
|
||||||
|
EOF
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
# Fetch and convert the icon
|
||||||
|
icon =
|
||||||
|
pkgs.runCommand "zenbrowser-icon"
|
||||||
|
{
|
||||||
|
nativeBuildInputs = [ pkgs.imagemagick ];
|
||||||
|
src = pkgs.fetchurl {
|
||||||
|
url = "https://raw.githubusercontent.com/zen-browser/desktop/163cc6b6bdfbf81673a0b5ea55ee7bf2eba46a42/configs/branding/release/logo.png";
|
||||||
|
sha256 = "9e27e02a924c73c0101757aa6f726ec6a91f7e908bcc900e9a4dab2c8cd3e61a";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
''
|
||||||
|
mkdir -p $out/share/icons/hicolor/512x512/apps
|
||||||
|
convert $src $out/share/icons/hicolor/512x512/apps/zen-browser.png
|
||||||
|
'';
|
||||||
|
|
||||||
|
in
|
||||||
|
{
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
zenbrowser
|
||||||
|
];
|
||||||
|
}
|
Loading…
Add table
Reference in a new issue