mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-02-07 06:19:00 +00:00
Update flakes and documentations
This commit is contained in:
parent
d4f15e4c0b
commit
e8b5f05bfd
2
.gitmodules
vendored
2
.gitmodules
vendored
@ -1,3 +1,3 @@
|
||||
[submodule "users/config"]
|
||||
path = users/foo-dogsquared/config
|
||||
path = users/home-manager/foo-dogsquared/config
|
||||
url = https://github.com/foo-dogsquared/dotfiles.git
|
||||
|
@ -46,9 +46,8 @@ nixos-config
|
||||
This usually configures like the hardware setup, timezone, and users.
|
||||
Host configurations are also exported in the flakes in `outputs.nixosConfigurations`.
|
||||
|
||||
* link:./modules/[`./modules/`] contain my custom modules including for NixOS and home-manager.
|
||||
* link:./modules/[`./modules/`] contain my custom modules including NixOS and home-manager modules.
|
||||
For more information, see the link:./modules/README.adoc[related documentation].
|
||||
It is also exported from the flake in `outputs.nixosModules`.
|
||||
|
||||
* link:./pkgs/[`./pkgs/`] contains my custom packages.
|
||||
It is exported in the flakes at `outputs.packages` compiled through various systems (but only `x86_64-linux` is mainly tested).
|
||||
@ -66,6 +65,7 @@ In order of priority:
|
||||
|
||||
* [x] Create custom modules.
|
||||
* [x] Create a themes system similar to link:https://github.com/hlissner/dotfiles[this NixOS config].
|
||||
* [ ] Create development shells.
|
||||
* [x] Manage secrets with agenix.
|
||||
* [ ] Create link:https://github.com/numtide/devshell[devshells].
|
||||
* [x] Automate backups with NixOS config.
|
||||
|
30
flake.lock
generated
30
flake.lock
generated
@ -7,11 +7,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1638319138,
|
||||
"narHash": "sha256-ve33f4nTKQluyvm5URQwL019x0Fnrg8urqzvymNeD+s=",
|
||||
"lastModified": 1638748414,
|
||||
"narHash": "sha256-5lII/CiiO1tobd92RMpVcwDAWVdpIvQdHCMT9kLRtk0=",
|
||||
"owner": "ryantm",
|
||||
"repo": "agenix",
|
||||
"rev": "52ea2f8c3231cc2b5302fa28c63588aacb77ea29",
|
||||
"rev": "c53ac31e44285ef77f239cc985aa43c03533172f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -81,11 +81,11 @@
|
||||
},
|
||||
"locked": {
|
||||
"dir": "contrib",
|
||||
"lastModified": 1638653427,
|
||||
"narHash": "sha256-4GjEJ3skxI7qrdh75bDfsmHo7QHkWWDo3waQ3Hotej4=",
|
||||
"lastModified": 1638765202,
|
||||
"narHash": "sha256-eW/ZDUrfP8rD8a5Rotqo8i5PKiK7UFWe75DgMLAtenY=",
|
||||
"owner": "neovim",
|
||||
"repo": "neovim",
|
||||
"rev": "1e6eeca9d1360554ee18525603e83c3a1999a622",
|
||||
"rev": "523f03b506bf577811c0e136bc852cdb89f92c00",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -102,11 +102,11 @@
|
||||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1638692002,
|
||||
"narHash": "sha256-qA5erdDRylHAdbWcSaa5MLQi5T7lwlNOcglvNt2GMbY=",
|
||||
"lastModified": 1638778450,
|
||||
"narHash": "sha256-C5UoHcRk5YjKNz9bVv+Kp28PjT/A+R49rUlpa1hFxvU=",
|
||||
"owner": "nix-community",
|
||||
"repo": "neovim-nightly-overlay",
|
||||
"rev": "ccbfeaac2c0b0cae2ab48a1dca49cba4f4ac9b8c",
|
||||
"rev": "740f1503ca2e5c066507e836bac13aa21c87da3b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -117,11 +117,11 @@
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1638376152,
|
||||
"narHash": "sha256-ucgLpVqhFnClH7YRUHBHnmiOd82RZdFR3XJt36ks5fE=",
|
||||
"lastModified": 1638535497,
|
||||
"narHash": "sha256-tk5LNbdkUhALp00+r5ZmQ3t7n2d5M7YUQB+MznWvVOg=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "6daa4a5c045d40e6eae60a3b6e427e8700f1c07f",
|
||||
"rev": "c71f061c68ba8ce53471b767d5049cbd0f3d8490",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -133,11 +133,11 @@
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1638432899,
|
||||
"narHash": "sha256-iZ+rgyRx3JVyylXYxSyW01liDWEn+O8cKnin6cMzOFU=",
|
||||
"lastModified": 1638671387,
|
||||
"narHash": "sha256-xjxuLNcbwoGU9UXuEbbsYigVDXANOI+09nlMTUAtxLQ=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "56cbe42f1668338d05febfbb866e32f2c865609a",
|
||||
"rev": "5a1f29a6574d5086cc6d97c2ab1eea4d0302ab94",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -1,8 +1,7 @@
|
||||
= Modules
|
||||
:toc:
|
||||
|
||||
These are the modules to be used for the system configuration.
|
||||
Multiple types of modules can be found here but the usual types of modules you'll be paying attention is the modules for link:https://nixos.org/manual/nixos/stable/index.html#sec-writing-modules[NixOS modules] and home-manager, both in link:./nixos/[`./nixos/`] and link:./home-manager/[`./home-manager/`], respectively.
|
||||
These are various modules ranging from link:https://nixos.org/manual/nixos/stable/index.html#sec-writing-modules[NixOS modules] and link:https://github.com/nix-community/home-manager[home-manager] modules.
|
||||
|
||||
The modules are imported usually through `lib.filesToAttr`, allowing for easier structuring without modifying the index file of each module (i.e., `default.nix`).
|
||||
(See the implementation for more details.)
|
||||
@ -11,7 +10,7 @@ For example, take the following module folder structure...
|
||||
|
||||
[source, tree]
|
||||
----
|
||||
system/
|
||||
nixos/
|
||||
├── themes/
|
||||
│ ├── a-happy-gnome/
|
||||
│ │ ├── default.nix
|
||||
@ -51,7 +50,7 @@ system/
|
||||
----
|
||||
|
||||
The resulting attribute set can be easily be used for importing.
|
||||
Here's an example of a NixOS system created with the NixOS modules which can used for shared configuration between hosts.
|
||||
Here's an example of a NixOS system created with the custom NixOS modules (i.e., link:./nixos/[`./nixos/`]) which can used for shared configuration between hosts.
|
||||
|
||||
[source, nix]
|
||||
----
|
||||
@ -60,3 +59,13 @@ lib.nixosSystem {
|
||||
modules = lib.mapAttrsToList (name: path: import path) (lib.filesToAttr ./modules/nixos);
|
||||
}
|
||||
----
|
||||
|
||||
|
||||
|
||||
|
||||
== Flake outputs
|
||||
|
||||
Various modules are then exported to the project flake as the following output:
|
||||
|
||||
* `nixosModules` exports modules from link:./nixos/[`./nixos/`].
|
||||
* `homeManagerModules` exports modules from link:./home-manager/[`./home-manager/`].
|
||||
|
Loading…
Reference in New Issue
Block a user