Update various files

This commit is contained in:
Gabriel Arazas 2022-01-25 09:32:17 +08:00
parent 84d0062ca8
commit a6a4b2b1e1
9 changed files with 29 additions and 15 deletions

View File

@ -40,18 +40,19 @@ It supports the default list of systems as defined from link:https://github.com/
* `devShells` from link:./shells/[my custom environments]. * `devShells` from link:./shells/[my custom environments].
Similar to `homeManagerConfigurations`, you can easily use it outside of NixOS. Similar to `homeManagerConfigurations`, you can easily use it outside of NixOS.
* `homeManagerConfigurations` contains my various link:https://github.com/nix-community/home-manager[home-manager] configurations from link:./users/home-manager/[`./users/home-manager/`].
The neat thing about it is you can easily install it in a non-NixOS Linux distro.
* `nixosConfigurations` which is where you can install my various NixOS configurations directly (e.g., `nixos-install --flake MY_FLAKE_URL#HOST`). * `nixosConfigurations` which is where you can install my various NixOS configurations directly (e.g., `nixos-install --flake MY_FLAKE_URL#HOST`).
This mainly uses the link:./hosts/[hosts configuration]. This mainly uses the link:./hosts/[hosts configuration].
* `homeManagerConfigurations` contains my various link:https://github.com/nix-community/home-manager[home-manager] configurations from link:./users/home-manager/[`./users/home-manager/`]. * `homeManagerModules` are where my link:./modules/home-manager[custom home-manager modules] to be exported.
The neat thing about it is you can easily install it in a non-NixOS Linux distro. footnote:[This is more useful than my NixOS modules.]
* `nixosModules` are composed from NixOS modules defined in link:./modules/nixos[`./modules/nixos`]. * `nixosModules` are composed from NixOS modules defined in link:./modules/nixos[`./modules/nixos`].
It can be used as additional modules for your own NixOS config in case you want to use mine for whatever reason. It can be used as additional modules for your own NixOS config in case you want to use mine for whatever reason.
footnote:[I don't know why did I put it there but eh...] footnote:[I don't know why did I put it there but eh...]
* `homeManagerModules` are where my link:./modules/home-manager[custom home-manager modules] to be exported.
footnote:[This is more useful than my NixOS modules.]
* `templates` which contains my templates. * `templates` which contains my templates.
Though, these are just templates mostly for my own purposes so it is not as useful as the other outputs. Though, these are just templates mostly for my own purposes so it is not as useful as the other outputs.

View File

@ -63,7 +63,7 @@
forAllSystems = f: forAllSystems = f:
nixpkgs.lib.genAttrs inputs.flake-utils.lib.defaultSystems nixpkgs.lib.genAttrs inputs.flake-utils.lib.defaultSystems
(system: f system); (system: f system);
libExtended = nixpkgs.lib.extend (final: prev: libExtended = nixpkgs.lib.extend (final: prev:
(import ./lib { lib = final; }) // { (import ./lib { lib = final; }) // {
@ -142,9 +142,16 @@
# Let home-manager to manage itself. # Let home-manager to manage itself.
programs.home-manager.enable = true; programs.home-manager.enable = true;
manual = {
html.enable = true;
json.enable = true;
manpages.enable = true;
};
}]; }];
}; };
in { in
{
# Exposes only my library with the custom functions to make it easier to # Exposes only my library with the custom functions to make it easier to
# include in other flakes. # include in other flakes.
lib = import ./lib { lib = nixpkgs.lib; }; lib = import ./lib { lib = nixpkgs.lib; };
@ -188,7 +195,6 @@
import ./shells { import ./shells {
pkgs = import nixpkgs { inherit system overlays; }; pkgs = import nixpkgs { inherit system overlays; };
}); });
};
# It is my go-to so it is the default template. # It is my go-to so it is the default template.
defaultTemplate = self.templates.basic-devshell; defaultTemplate = self.templates.basic-devshell;
@ -200,4 +206,5 @@
description = "Basic development shell template"; description = "Basic development shell template";
}; };
}; };
};
} }

View File

@ -37,5 +37,5 @@ imports = [ # Your modules ]
++ (lib.attrValues (lib.getUsers "nixos" [ "foo-dogsquared" "polski" ])); ++ (lib.attrValues (lib.getUsers "nixos" [ "foo-dogsquared" "polski" ]));
---- ----
* link:../modules/users.nix[`modules.users.users.${user}`] which is my implementation for managing users from link:../users/home-manager/[`../users/home-manager/`] — e.g., `modules.users.users.foo-dogsquared = {}`. * link:../modules/nixos/profiles/users.nix[`modules.users.users.${user}`] which is my implementation for managing users from link:../users/home-manager/[`../users/home-manager/`] — e.g., `modules.users.users.foo-dogsquared = {}`.
This is integrating my home-manager users to map into NixOS users. This is integrating my home-manager users to map into NixOS users.

View File

@ -35,7 +35,7 @@ in {
}; };
# This uses the custom borgmatic NixOS service. # This uses the custom borgmatic NixOS service.
services.borgmatic.jobs.external-storage = { services.borgmatic-fds.jobs.external-storage = {
startAt = "04/6:00:00"; startAt = "04/6:00:00";
configPath = config.age.secrets.external-backup-borgmatic-settings.path; configPath = config.age.secrets.external-backup-borgmatic-settings.path;
}; };

View File

@ -70,6 +70,9 @@ in {
# !!! Please add your user to the "libvirtd" group. # !!! Please add your user to the "libvirtd" group.
(lib.mkIf cfg.virtualization.enable { (lib.mkIf cfg.virtualization.enable {
# virt-manager as my frontend.
environment.systemPackages = [ pkgs.virt-manager ];
# Enable podman just as my main container runtime or something. # Enable podman just as my main container runtime or something.
virtualisation.podman = { virtualisation.podman = {
enable = true; enable = true;
@ -79,6 +82,7 @@ in {
# Enable libvirt for muh qemu. # Enable libvirt for muh qemu.
virtualisation.libvirtd = { virtualisation.libvirtd = {
enable = true; enable = true;
qemu.package = pkgs.qemu_full;
qemu.ovmf.enable = true; qemu.ovmf.enable = true;
}; };
}) })

View File

@ -2,7 +2,7 @@
{ config, options, lib, pkgs, ... }: { config, options, lib, pkgs, ... }:
let let
cfg = config.services.borgmatic; cfg = config.services.borgmatic-fds;
jobOption = { name, config, ... }: { jobOption = { name, config, ... }: {
options = { options = {
@ -27,7 +27,7 @@ let
}; };
}; };
in { in {
options.services.borgmatic = { options.services.borgmatic-fds = {
jobs = lib.mkOption { jobs = lib.mkOption {
type = with lib.types; attrsOf (submodule jobOption); type = with lib.types; attrsOf (submodule jobOption);
description = description =

View File

@ -1,5 +1,5 @@
{ pkgs ? import <nixpkgs> { } }: { pkgs ? import <nixpkgs> { } }:
pkgs.mkShell { pkgs.mkShell {
packages = with pkgs; [ git git-crypt nixfmt rnix-lsp ]; packages = with pkgs; [ asciidoctor git git-crypt nixfmt rnix-lsp ];
} }

View File

@ -3,7 +3,7 @@
# projects. # projects.
# #
# These include toolkits for C, Rust, and GNOME JavaScript. # These include toolkits for C, Rust, and GNOME JavaScript.
{ mkShell, meson, ninja, gtk4, libadwaita, gjs, pkg-config, rustPlatform, nodePackages }: { mkShell, cmake, meson, ninja, gtk4, libadwaita, gjs, pkg-config, rustPlatform, nodePackages }:
mkShell { mkShell {
packages = [ packages = [

View File

@ -4,14 +4,16 @@
# It's a good thing they have documented the full details in one of their # It's a good thing they have documented the full details in one of their
# manuals at # manuals at
# https://www.gnu.org/software/automake/manual/html_node/GNU-Build-System.html # https://www.gnu.org/software/automake/manual/html_node/GNU-Build-System.html
{ mkShell, lib, autoconf, autoconf-archive, automake, gnumake, gcc }: { mkShell, lib, autoconf, autoconf-archive, automake, gnumake, gcc, gettext, coreutils, pkg-config }:
mkShell { mkShell {
packages = [ packages = [
autoconf autoconf
autoconf-archive autoconf-archive
automake automake
gnumake coreutils
gettext
gcc gcc
pkg-config
]; ];
} }