Alejandra'd repo, added better dry run script.
All checks were successful
Build Nix modules (dry-run) / build-modules (push) Successful in 3m32s
All checks were successful
Build Nix modules (dry-run) / build-modules (push) Successful in 3m32s
This commit is contained in:
parent
32cf42d11d
commit
387fb668b3
11 changed files with 101 additions and 64 deletions
|
|
@ -14,19 +14,20 @@ TODO HECK
|
|||
|
||||
- [x] Do a massive overhaul of the file structure, like there should be like modules where it is possible to call things to be packages. I.e. Calling the OVMF/SeaBIOS + Gnome/Plasma/Sway + Local changes, which two former would be separate .nix files. -> Probably will do a V3 or v2.1 later on when mature
|
||||
- [ ] Add the .env for the configurations so that we add the `git config --global user.email "you@example.com"` and `git config --global user.name "Your Name"` with the account custom made for this.
|
||||
- [?] Clean up the hanging configurations -> PiHole DNS Stuff needs to be transferred over elegantly, don't want to touch it unless I am myself en-site.
|
||||
- [ ] Clean up the hanging configurations -> PiHole DNS Stuff needs to be transferred over elegantly, don't want to touch it unless I am myself en-site.
|
||||
- [x] Find a more clean way to store initial passwords (.env??) -> [nix-sops](https://github.com/Mic92/sops-nix)
|
||||
- [?] Create proper build automation scripts -> Needs to be properly done.
|
||||
- [x] Create proper build automation scripts -> Needs to be properly done.
|
||||
- [ ] Attach more NixOS weblinks...
|
||||
- [ ] Update Forgejo Styling
|
||||
- [x] Figure out what the ***hecc*** to do with SSL Certifications in the most elegant way -> Use Traefik
|
||||
- [x] Add Git Actions to Forgejo -> It was already added, just need to setup the CI itself.
|
||||
- [ ] Setup the CI backend.
|
||||
- [x] Setup the CI backend.
|
||||
- [x] Create the Podman x Portainer NixOS module -> See `Songsheet`
|
||||
- [ ] Read up more about how to a backup machine stuff and making it Nix-y...
|
||||
- [ ] Figure out my life
|
||||
- [ ] Setup Hardware Keys
|
||||
- [ ] Setup a VPN (Likely OpenVPN)
|
||||
- [x] Setup a VPN
|
||||
- [ ] Setup Alejandra pre-commit hook
|
||||
|
||||
|
||||
## NOTES FOR FUTURE
|
||||
|
|
|
|||
39
dry_run.zsh
39
dry_run.zsh
|
|
@ -21,8 +21,43 @@ if [[ -n "$1" ]]; then
|
|||
configs=("$1")
|
||||
fi
|
||||
|
||||
# Track results
|
||||
passed_configs=()
|
||||
failed_configs=()
|
||||
|
||||
for config in "${configs[@]}"; do
|
||||
echo "=== Dry-run: $config ==="
|
||||
nix build --dry-run ".#nixosConfigurations.${config}.config.system.build.toplevel" || true
|
||||
echo "Dry-run: $config ==="
|
||||
if nix build --dry-run ".#nixosConfigurations.${config}.config.system.build.toplevel" 2>&1; then
|
||||
echo "[PASSED]: $config"
|
||||
passed_configs+=("$config")
|
||||
else
|
||||
echo "[FAILED]: $config"
|
||||
failed_configs+=("$config")
|
||||
fi
|
||||
echo
|
||||
done
|
||||
|
||||
# Print summary
|
||||
echo "BUILD SUMMARY"
|
||||
echo "Total: ${#configs[@]} | Passed: ${#passed_configs[@]} | Failed: ${#failed_configs[@]}"
|
||||
echo
|
||||
|
||||
if [[ ${#passed_configs[@]} -gt 0 ]]; then
|
||||
echo "Passed configs:"
|
||||
for c in "${passed_configs[@]}"; do
|
||||
echo " - $c"
|
||||
done
|
||||
echo
|
||||
fi
|
||||
|
||||
if [[ ${#failed_configs[@]} -gt 0 ]]; then
|
||||
echo "Failed configs:"
|
||||
for c in "${failed_configs[@]}"; do
|
||||
echo " - $c"
|
||||
done
|
||||
echo
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "All configurations passed!"
|
||||
exit 0
|
||||
|
|
|
|||
|
|
@ -34,5 +34,4 @@
|
|||
owner = "root";
|
||||
mode = "0400";
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@
|
|||
fsType = "ext4";
|
||||
};
|
||||
};
|
||||
|
||||
in {
|
||||
options.local = {
|
||||
hostname = lib.mkOption {
|
||||
|
|
@ -38,13 +37,15 @@ in {
|
|||
};
|
||||
};
|
||||
|
||||
imports = [
|
||||
imports =
|
||||
[
|
||||
(choose [./modules/local/hostname_username.nix ../local/hostname_username.nix])
|
||||
(choose [./modules/local/networking_local.nix ../local/networking_local.nix])
|
||||
(choose [./modules/lix-default.nix ../lix-default.nix])
|
||||
(choose [./modules/secrets-config/sops-build-machine.nix ../secrets-config/sops-build-machine.nix])
|
||||
## TODO: Make this more elegant and less risky for unexpected errors happening.
|
||||
] ++ lib.optional (builtins.pathExists ./hardware-configuration.nix) ./hardware-configuration.nix
|
||||
]
|
||||
++ lib.optional (builtins.pathExists ./hardware-configuration.nix) ./hardware-configuration.nix
|
||||
++ lib.optional (!builtins.pathExists ./hardware-configuration.nix) dummyFileSystems;
|
||||
|
||||
config = {
|
||||
|
|
@ -180,7 +181,6 @@ in {
|
|||
defaultNetwork.settings.dns_enabled = true;
|
||||
};
|
||||
|
||||
|
||||
# Network configuration for the build machine on the Proxmox bridge
|
||||
networking.interfaces.ens18.ipv4.addresses = [
|
||||
{
|
||||
|
|
|
|||
|
|
@ -29,7 +29,8 @@ in {
|
|||
};
|
||||
};
|
||||
|
||||
imports = [
|
||||
imports =
|
||||
[
|
||||
(choose [./modules/desktop-manager/gnome.nix ../desktop-manager/gnome.nix])
|
||||
(choose [./modules/local/hostname_username.nix ../local/hostname_username.nix])
|
||||
(choose [./modules/local/networking_local.nix ../local/networking_local.nix])
|
||||
|
|
@ -38,7 +39,8 @@ in {
|
|||
(choose [./modules/secrets-config/sops-database.nix ../secrets-config/sops-database.nix])
|
||||
(choose [./modules/system_scripts/gcloud_backup.nix ../system_scripts/gcloud_backup.nix])
|
||||
## TODO: Make this more elegant and less risky for unexpected errors happening.
|
||||
] ++ lib.optional (builtins.pathExists ./hardware-configuration.nix) ./hardware-configuration.nix;
|
||||
]
|
||||
++ lib.optional (builtins.pathExists ./hardware-configuration.nix) ./hardware-configuration.nix;
|
||||
|
||||
config = {
|
||||
local.hostname = "nixosdd";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue