reorganised hosts

This commit is contained in:
2021-06-04 02:06:13 +05:30
parent 02fa695a0f
commit 517b2804e5
21 changed files with 111 additions and 38 deletions

View File

@@ -10,7 +10,6 @@
start = [ start = [
auto-pairs auto-pairs
vim-floaterm vim-floaterm
vim-rooter
vim-closetag vim-closetag
vim-floaterm vim-floaterm
nerdcommenter nerdcommenter
@@ -20,8 +19,8 @@
barbar-nvim barbar-nvim
nvim-web-devicons nvim-web-devicons
vim-polyglot vim-polyglot
coc-explorer
(gruvbox.overrideAttrs (oa: { patches = [ ./nvim/gruvbox.patch ]; })) (gruvbox.overrideAttrs (oa: { patches = [ ./nvim/gruvbox.patch ]; }))
# (gruvbox.overrideAttrs (oa: { src = pkgs.fetchFromGitHub{} }))
]; ];
}; };
}; };

View File

@@ -79,6 +79,8 @@ bind('n', "<C-m>", "<C-w>h", {noremap=true})
bind('n', "<C-n>", "<C-w>j", {noremap=true}) bind('n', "<C-n>", "<C-w>j", {noremap=true})
bind('n', "<C-e>", "<C-w>k", {noremap=true}) bind('n', "<C-e>", "<C-w>k", {noremap=true})
bind('n', "<C-i>", "<C-w>l", {noremap=true}) bind('n', "<C-i>", "<C-w>l", {noremap=true})
bind('n', "<C-v>", ":vsplit<CR>", {noremap=true, silent=true})
bind('n', "<C-h>", ":split<CR>", {noremap=true, silent=true})
--RUN AND REPL (using vim-floaterm) --RUN AND REPL (using vim-floaterm)

58
flake.lock generated
View File

@@ -85,6 +85,25 @@
"type": "github" "type": "github"
} }
}, },
"mailserver": {
"inputs": {
"nixpkgs": "nixpkgs_2",
"utils": "utils"
},
"locked": {
"lastModified": 1622699922,
"narHash": "sha256-KJ2R+URPXVCdignP9v2eCA+/YwiNYY5HSQ0/Szv47KM=",
"owner": "simple-nixos-mailserver",
"repo": "nixos-mailserver",
"rev": "49074b7835c6d40846cb23953c04a03e1d2a4a9e",
"type": "gitlab"
},
"original": {
"owner": "simple-nixos-mailserver",
"repo": "nixos-mailserver",
"type": "gitlab"
}
},
"neovim-flake": { "neovim-flake": {
"inputs": { "inputs": {
"flake-utils": "flake-utils_2", "flake-utils": "flake-utils_2",
@@ -123,6 +142,21 @@
} }
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": {
"lastModified": 1607522989,
"narHash": "sha256-o/jWhOSAlaK7y2M57OIriRt6whuVVocS/T0mG7fd1TI=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "e9158eca70ae59e73fae23be5d13d3fa0cfc78b4",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-unstable",
"type": "indirect"
}
},
"nixpkgs_3": {
"locked": { "locked": {
"lastModified": 1619464443, "lastModified": 1619464443,
"narHash": "sha256-R7WAb8EnkIJxxaF6GTHUPytjonhB4Zm0iatyWoW169A=", "narHash": "sha256-R7WAb8EnkIJxxaF6GTHUPytjonhB4Zm0iatyWoW169A=",
@@ -138,7 +172,7 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_3": { "nixpkgs_4": {
"locked": { "locked": {
"lastModified": 1621840840, "lastModified": 1621840840,
"narHash": "sha256-o6h6+d5ZwrFmOTe+ma9s1Z9kyHsCW1C84IA8RZ9/fIU=", "narHash": "sha256-o6h6+d5ZwrFmOTe+ma9s1Z9kyHsCW1C84IA8RZ9/fIU=",
@@ -173,7 +207,7 @@
"inputs": { "inputs": {
"flake-compat": "flake-compat", "flake-compat": "flake-compat",
"neovim-flake": "neovim-flake", "neovim-flake": "neovim-flake",
"nixpkgs": "nixpkgs_3" "nixpkgs": "nixpkgs_4"
}, },
"locked": { "locked": {
"lastModified": 1622104855, "lastModified": 1622104855,
@@ -193,11 +227,12 @@
"inputs": { "inputs": {
"agenix": "agenix", "agenix": "agenix",
"home-manager": "home-manager", "home-manager": "home-manager",
"nixpkgs": "nixpkgs_2", "mailserver": "mailserver",
"nixpkgs": "nixpkgs_3",
"nur": "nur", "nur": "nur",
"nvim": "nvim", "nvim": "nvim",
"stable": "stable", "stable": "stable",
"utils": "utils" "utils": "utils_2"
} }
}, },
"stable": { "stable": {
@@ -217,6 +252,21 @@
} }
}, },
"utils": { "utils": {
"locked": {
"lastModified": 1605370193,
"narHash": "sha256-YyMTf3URDL/otKdKgtoMChu4vfVL3vCMkRqpGifhUn0=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "5021eac20303a61fafe17224c087f5519baed54d",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"utils_2": {
"locked": { "locked": {
"lastModified": 1620759905, "lastModified": 1620759905,
"narHash": "sha256-WiyWawrgmyN0EdmiHyG2V+fqReiVi8bM9cRdMaKQOFg=", "narHash": "sha256-WiyWawrgmyN0EdmiHyG2V+fqReiVi8bM9cRdMaKQOFg=",

View File

@@ -13,6 +13,7 @@
agenix.url = github:ryantm/agenix; agenix.url = github:ryantm/agenix;
utils.url = github:numtide/flake-utils; utils.url = github:numtide/flake-utils;
nvim.url = github:nix-community/neovim-nightly-overlay; nvim.url = github:nix-community/neovim-nightly-overlay;
mailserver.url = gitlab:simple-nixos-mailserver/nixos-mailserver;
}; };
outputs = inputs@{self, nixpkgs, stable, ... }: outputs = inputs@{self, nixpkgs, stable, ... }:
@@ -26,7 +27,10 @@
{ {
packages = import nixpkgs { packages = import nixpkgs {
inherit system; inherit system;
overlays = overlays ++ [ inputs.nur.overlay inputs.nvim.overlay ]; overlays = overlays ++ [
inputs.nur.overlay
inputs.nvim.overlay
];
config.allowUnfree = true; config.allowUnfree = true;
config.allowBroken = true; config.allowBroken = true;
}; };
@@ -67,6 +71,7 @@
system = "aarch64-linux"; system = "aarch64-linux";
modules = [ modules = [
./hosts/servers/marisa.nix ./hosts/servers/marisa.nix
inputs.mailserver.nixosModules.mailserver
{ {
nixpkgs.pkgs = self.packages.aarch64-linux; nixpkgs.pkgs = self.packages.aarch64-linux;
} }

View File

@@ -71,7 +71,6 @@ in
glxinfo glxinfo
sxiv sxiv
vim vim
w3m
feh feh
dwm dwm
dmenu dmenu

Binary file not shown.

View File

@@ -10,8 +10,8 @@
package = pkgs.firefox-bin; package = pkgs.firefox-bin;
profiles.natto = { profiles.natto = {
name = "natto"; name = "natto";
userChrome = builtins.readFile ../config/firefox/userChrome.css; # userChrome = builtins.readFile ../config/firefox/userChrome.css;
userContent = builtins.readFile ../config/firefox/userContent.css; # userContent = builtins.readFile ../config/firefox/userContent.css;
}; };
}; };
zathura = { zathura = {

View File

@@ -1,21 +0,0 @@
{config, ... }:
{
networking = {
hostName = "Satori";
wireless.enable = true; # Enables wireless support via wpa_supplicant.
firewall.allowedTCPPorts = [ 22 ];
interfaces = {
enp7s0.useDHCP = true;
wlp0s20f3 = {
useDHCP = true;
ipv4.addresses = [ {
prefixLength = 24;
address = "192.168.0.109";
} ];
};
};
defaultGateway = "192.168.0.1";
nameservers = [ "1.1.1.1" "8.8.8.8" ];
};
}

View File

@@ -11,7 +11,7 @@
./common/nvidia-offload.nix ./common/nvidia-offload.nix
./common/pipewire.nix ./common/pipewire.nix
./common/xorg.nix ./common/xorg.nix
./configs/nvim.nix ../../configs/nvim.nix
]; ];
system.stateVersion = "20.09"; system.stateVersion = "20.09";
} }

View File

@@ -21,7 +21,7 @@
}; };
grub = { grub = {
enable = true; enable = true;
useOSProber = true; # useOSProber = true;
efiSupport = true; efiSupport = true;
device = "nodev"; device = "nodev";
splashImage = ./cirno.png; splashImage = ./cirno.png;

View File

Before

Width:  |  Height:  |  Size: 34 KiB

After

Width:  |  Height:  |  Size: 34 KiB

View File

@@ -0,0 +1,37 @@
{config, pkgs, ... }:
{
networking = {
hostName = "Satori";
wireless.enable = true;
firewall = {
allowedTCPPorts = [ 22 ];
allowedUDPPorts = [ 17840 ];
};
interfaces = {
enp7s0.useDHCP = true;
wlp0s20f3 = {
useDHCP = true;
ipv4.addresses = [ {
prefixLength = 24;
address = "192.168.0.109";
} ];
};
};
wireguard.interfaces.wg0 = {
ips = [ "100.0.0.3/32" ];
listenPort = 17840;
privateKeyFile = "/var/secrets/wg";
peers = [
{
#Oracle VM1
publicKey = "z0Y2VNEWcyVQVSqRHiwmiJ5/0MgSPM+HZfEcwIccSxM=";
allowedIPs = [ "100.0.0.0/24" ];
endpoint = "140.238.230.155:17840";
persistentKeepalive = 25;
}
];
};
nameservers = [ "1.1.1.1" "8.8.8.8" ];
};
}

View File

@@ -20,7 +20,10 @@
package = pkgs.mysql; package = pkgs.mysql;
dataDir = "/var/db"; dataDir = "/var/db";
}; };
sshd.enable = true; openssh = {
enable = true;
permitRootLogin = "yes";
};
/* vault = { /* vault = {
enable = true; enable = true;
storageBackend = "mysql"; storageBackend = "mysql";
@@ -30,7 +33,7 @@
systemd.services = { systemd.services = {
tor.wantedBy = lib.mkForce []; tor.wantedBy = lib.mkForce [];
logmein-hamachi.wantedBy = lib.mkForce []; logmein-hamachi.wantedBy = lib.mkForce [];
sshd.wantedBy = lib.mkForce []; openssh.wantedBy = lib.mkForce [];
mysql.wantedBy = lib.mkForce []; mysql.wantedBy = lib.mkForce [];
#printing.wantedBy = lib.mkForce []; #printing.wantedBy = lib.mkForce [];
#vault.wantedBy = lib.mkForce []; #vault.wantedBy = lib.mkForce [];

View File

@@ -13,7 +13,6 @@ fi
keys="" keys=""
for x in ~/.ssh/*.pub for x in ~/.ssh/*.pub
do do
keys= "$keys -r $(cat 'x')" keys="$keys -r \"$(cat "$x")\""
done done
echo "Encrypting with \n'$keys'" echo rage -o $TARGET $keys $FILE
rage -o "$TARGET" "$keys" "$1"