Merge branch 'main' of gh:greg-hellings/nixos-config
This commit is contained in:
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
{
|
{
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
|
buildifier
|
||||||
gopls
|
gopls
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,11 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
set -ex
|
||||||
|
|
||||||
|
|
||||||
|
curl -s https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts | sed '1,33d' > /etc/adblock_hosts
|
||||||
|
|
||||||
|
# Custom domains that I need to preserve for some reason
|
||||||
|
sed -i -e '/segment.com/d' /etc/adblock_hosts # Blocks Trelly content for house investors
|
||||||
|
sed -i -e '/segment.io/d' /etc/adblock_hosts # Blocks Trelly content for house investors
|
||||||
|
|
||||||
|
systemctl restart dnsmasq
|
||||||
@@ -24,6 +24,8 @@ let
|
|||||||
];
|
];
|
||||||
|
|
||||||
lanDevice = "enp1s0";
|
lanDevice = "enp1s0";
|
||||||
|
|
||||||
|
adblockUpdate = pkgs.writeShellScriptBin "adblockUpdate" (builtins.readFile ./adblockUpdate.sh);
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
# Enable the service with its own configuration
|
# Enable the service with its own configuration
|
||||||
@@ -90,13 +92,16 @@ in
|
|||||||
};
|
};
|
||||||
extraConfig = "${extraConfig}";
|
extraConfig = "${extraConfig}";
|
||||||
};
|
};
|
||||||
environment.systemPackages = [ pkgs.curl ];
|
environment.systemPackages = with pkgs; [
|
||||||
|
busybox
|
||||||
|
curl
|
||||||
|
];
|
||||||
|
|
||||||
# Regularly update DNS block list
|
# Regularly update DNS block list
|
||||||
services.cron = {
|
services.cron = {
|
||||||
enable = true;
|
enable = true;
|
||||||
systemCronJobs = [
|
systemCronJobs = [
|
||||||
"* * * * * root ( ${pkgs.curl}/bin/curl -s https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts | sed '1,33d' > /etc/adblock_hosts && systemctl restart dnsmasq ) 2>&1 > /var/log/adblock.log"
|
"* * * * * root ${adblockUpdate} 2>&1 > /var/log/adblock.log"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -60,7 +60,6 @@
|
|||||||
hms # My own home manager switcher
|
hms # My own home manager switcher
|
||||||
htop
|
htop
|
||||||
killall
|
killall
|
||||||
lshw
|
|
||||||
nano
|
nano
|
||||||
pciutils
|
pciutils
|
||||||
pwgen
|
pwgen
|
||||||
|
|||||||
@@ -15,6 +15,10 @@
|
|||||||
./tailscale.nix
|
./tailscale.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
lshw
|
||||||
|
];
|
||||||
|
|
||||||
system.stateVersion = "22.05";
|
system.stateVersion = "22.05";
|
||||||
|
|
||||||
nix.gc.dates = "weekly";
|
nix.gc.dates = "weekly";
|
||||||
|
|||||||
Reference in New Issue
Block a user