Compare commits

..

No commits in common. "713b835f70c7147c49d761c3275b21e0de984093" and "1510c8c31fe933ee9bb6ace01a6f4afc210a76c5" have entirely different histories.

8 changed files with 64 additions and 62 deletions

View File

@ -162,27 +162,28 @@
# Disk formatting, only used once
diskoConfigurations = { root = import ./disks/root.nix; };
packages = let
aws = system:
import ./generators/aws { inherit inputs globals overlays system; };
staff = system:
import ./generators/staff { inherit inputs globals overlays system; };
neovim = system:
let pkgs = import nixpkgs { inherit system overlays; };
in import ./modules/common/neovim/package {
inherit pkgs;
colors = (import ./colorscheme/gruvbox-dark).dark;
# Other packages, such as system images or programs
packages = forAllSystems (system: {
# Package servers into images with a generator
aws = {
"${system}" =
import ./generators/aws { inherit inputs globals system overlays; };
};
staff = {
"${system}" = import ./generators/staff {
inherit inputs globals system overlays;
};
in {
x86_64-linux.aws = aws "x86_64-linux";
x86_64-linux.staff = staff "x86_64-linux";
};
# Package Neovim config into standalone package
x86_64-linux.neovim = neovim "x86_64-linux";
x86_64-darwin.neovim = neovim "x86_64-darwin";
aarch64-linux.neovim = neovim "aarch64-linux";
aarch64-darwin.neovim = neovim "aarch64-darwin";
};
neovim = let pkgs = import nixpkgs { inherit system overlays; };
in import ./modules/common/neovim/package {
inherit pkgs;
colors = (import ./colorscheme/gruvbox-dark).dark;
};
});
# Programs that can be run by calling this flake
apps = forAllSystems (system:
@ -207,6 +208,8 @@
buildInputs = with pkgs; [ git stylua nixfmt shfmt shellcheck ];
};
test = pkgs.mkShell { buildInputs = with pkgs; [ age ]; };
# Used for cloud and systems development and administration
devops = pkgs.mkShell {
buildInputs = with pkgs; [

View File

@ -1,4 +1,4 @@
{ inputs, system, globals, overlays, ... }:
{ inputs, globals, ... }:
with inputs;
@ -8,7 +8,6 @@ nixos-generators.nixosGenerate {
modules = [
home-manager.nixosModules.home-manager
{
nixpkgs.overlays = overlays;
user = globals.user;
fullName = globals.fullName;
dotfilesRepo = globals.dotfilesRepo;
@ -16,7 +15,7 @@ nixos-generators.nixosGenerate {
gitEmail = globals.gitEmail;
networking.hostName = "sheep";
gui.enable = false;
theme.colors = (import ../../colorscheme/gruvbox).dark;
colorscheme = (import ../colorscheme/gruvbox);
passwordHash = null;
publicKey =
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIB+AbmjGEwITk5CK9y7+Rg27Fokgj9QEjgc9wST6MA3s";
@ -25,7 +24,7 @@ nixos-generators.nixosGenerate {
}
../../modules/common
../../modules/nixos
../../modules/nixos/services/sshd.nix
../../modules/common/services/sshd.nix
] ++ [
# Required to fix diskSize errors during build
({ ... }: { amazonImage.sizeMB = 16 * 1024; })

View File

@ -34,7 +34,9 @@ nixos-generators.nixosGenerate {
curl
(import ../../modules/common/neovim/package {
inherit pkgs;
colors = (import ../../colorscheme/gruvbox).dark;
# colors = import ../../colorscheme/gruvbox.dark.neovimConfig {
# inherit pkgs;
# };
})
];
nix.extraOptions = ''

View File

@ -28,6 +28,10 @@ nixpkgs.lib.nixosSystem {
# FQDNs for various services
networking.hostName = "flame";
bookServer = "books.masu.rs";
# streamServer = "stream.masu.rs";
nextcloudServer = "cloud.masu.rs";
transmissionServer = "download.masu.rs";
metricsServer = "metrics.masu.rs";
vaultwardenServer = "vault.masu.rs";
giteaServer = "git.masu.rs";
@ -43,40 +47,40 @@ nixpkgs.lib.nixosSystem {
accessKeyId = "0026b0e73b2e2c80000000005";
};
# # Grant access to Jellyfin directories from Nextcloud
# users.users.nextcloud.extraGroups = [ "jellyfin" ];
# Grant access to Jellyfin directories from Nextcloud
users.users.nextcloud.extraGroups = [ "jellyfin" ];
# # Wireguard config for Transmission
# wireguard.enable = true;
# networking.wireguard.interfaces.wg0 = {
#
# # The local IPs for this machine within the Wireguard network
# # Any inbound traffic bound for these IPs should be kept on localhost
# ips = [ "10.66.13.200/32" "fc00:bbbb:bbbb:bb01::3:dc7/128" ];
#
# peers = [{
#
# # Identity of Wireguard target peer (VPN)
# publicKey = "bOOP5lIjqCdDx5t+mP/kEcSbHS4cZqE0rMlBI178lyY=";
#
# # The public internet address of the target peer
# endpoint = "86.106.143.132:51820";
#
# # Which outgoing IP ranges should be sent through Wireguard
# allowedIPs = [ "0.0.0.0/0" "::0/0" ];
#
# # Send heartbeat signal within the network
# persistentKeepalive = 25;
#
# }];
#
# };
# Wireguard config for Transmission
wireguard.enable = true;
networking.wireguard.interfaces.wg0 = {
# # VPN port forwarding
# services.transmission.settings.peer-port = 57599;
# The local IPs for this machine within the Wireguard network
# Any inbound traffic bound for these IPs should be kept on localhost
ips = [ "10.66.13.200/32" "fc00:bbbb:bbbb:bb01::3:dc7/128" ];
# # Grant access to Transmission directories from Jellyfin
# users.users.jellyfin.extraGroups = [ "transmission" ];
peers = [{
# Identity of Wireguard target peer (VPN)
publicKey = "bOOP5lIjqCdDx5t+mP/kEcSbHS4cZqE0rMlBI178lyY=";
# The public internet address of the target peer
endpoint = "86.106.143.132:51820";
# Which outgoing IP ranges should be sent through Wireguard
allowedIPs = [ "0.0.0.0/0" "::0/0" ];
# Send heartbeat signal within the network
persistentKeepalive = 25;
}];
};
# VPN port forwarding
services.transmission.settings.peer-port = 57599;
# Grant access to Transmission directories from Jellyfin
users.users.jellyfin.extraGroups = [ "transmission" ];
# Proxy traffic with Cloudflare
cloudflare.enable = true;

View File

@ -39,12 +39,10 @@ nixpkgs.lib.nixosSystem {
nixpkgs.overlays = overlays;
neovim.enable = true;
caddy.enable = true;
cloudflare.enable = true;
streamServer = "stream.masu.rs";
nextcloudServer = "cloud.masu.rs";
bookServer = "books.masu.rs";
arrServer = "download.masu.rs";
transmissionServer = "download.masu.rs";
samba.enable = true;
backup.s3 = {

View File

@ -11,10 +11,6 @@
config = lib.mkIf (config.streamServer != null) {
services.jellyfin.enable = true;
users.users.jellyfin = {
isSystemUser = true;
group = "jellyfin";
};
caddy.routes = [{
match = [{ host = [ config.streamServer ]; }];

View File

@ -14,7 +14,7 @@
services.nextcloud = {
enable = true;
package = pkgs.nextcloud26; # Required to specify
package = pkgs.nextcloud25; # Required to specify
datadir = "/data/nextcloud";
https = true;
hostName = "localhost";

View File

@ -38,7 +38,7 @@ in {
};
secrets.vaultwarden = {
source = ../../../private/vaultwarden.age;
source = ../../private/vaultwarden.age;
dest = "${config.secretsDirectory}/vaultwarden";
owner = "vaultwarden";
group = "vaultwarden";