feat: replace snowfall lib with custom nix library #1

Merged
thunderbottom merged 4 commits from refactor/rm-snowfall-lib into main 2025-06-22 20:43:05 +02:00
No description provided.
snowfall-lib no longer seems to be maintained, and although it works
for now, replacing it with a custom library seems to be the right choice

the custom nix lib will be dead simple, and will take care of the entire
configuration

so for now, we start off by replacing `${namespace}` with `snowflake`
hardcoded, because it seems completely unnecessary to add a new variable
and anyone wanting to use this repository can do so by simply running a
sed command to replace `snowflake` in all files if they don't like it.

Signed-off-by: Chinmay D. Pai <chinmaydpai@gmail.com>
as stated in the previous commit message, replacing snowfall-lib right
now seems like an easier option than to continue using it and replacing
at a later point in time.

this "new" structure, along with the new lib, is mostly backwards-compatible
with snowfall-lib, so migrating over has been fairly simple, given that
we replaced most of the functionality with simple nix and some flake-parts
for "multi-system" configuration.

each of the folders: hosts, modules, overlays, packages, templates, contains
a default.nix defining the library functions to automate most of the nix
stuff for us.

except for refining the overlays, and replacing the namespace variable in
all files (thanks, sed), not much changes were required.

although, the entire configuration is now restructured, some reusable modules
have been added to `shared.nix` wherever required. home-manager is directly
integrated into nix, so no need to run a separate command for it.

everything looks alright, except the initial rebuild requires an experimental
nix feature: `pipe-operators`, which can be set during rebuild using:

```nix
sudo NIX_CONFIG="experimental-features = nix-command flakes auto-allocate-uids ca-derivations cgroups recursive-nix pipe-operators" nixos-rebuild switch --flake '.'
```

subsequent rebuilds do not require this since it's been added to nix.conf

overall, I believe we have reduced quite a bit of bloat, or at least got rid
of some unnecessary libraries, and made our configuration a bit more easier
to comprehend.

Signed-off-by: Chinmay D. Pai <chinmaydpai@gmail.com>
the new libxml2 ABI changes broke lttng-tools, which is a dependency for
paperless-ngx.

this overlay uses an unreleased version of lttng-tools to fix the build issue

paperless-ngx has some broken tests, possibly because of these changes, so
there's an overlay to disable the broken tests

Signed-off-by: Chinmay D. Pai <chinmaydpai@gmail.com>
Signed-off-by: Chinmay D. Pai <chinmaydpai@gmail.com>
thunderbottom deleted branch refactor/rm-snowfall-lib 2025-06-22 20:43:17 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
thunderbottom/flakes!1
No description provided.