Skip to content

Commit

Permalink
feat(configurations)!: flatten down, introduce meta.nix
Browse files Browse the repository at this point in the history
Flatten down directory structure:
- From: `./hosts/${configuration-type}/${system}/{configuration,deploy}.nix`
-   To: `./hosts/${configuration-type}/{meta,configuration}.nix`
Keep `system` and `deploy-rs` config in `meta.nix`
Update `flake.lock`
  • Loading branch information
reo101 committed Aug 13, 2024
1 parent 2973855 commit 9b8f894
Show file tree
Hide file tree
Showing 43 changed files with 459 additions and 344 deletions.
90 changes: 45 additions & 45 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 5 additions & 6 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
./modules/flake/modules
./modules/flake/configurations
./modules/flake/agenix
./modules/flake/deploy
./modules/flake/topology
./modules/flake/packages
./modules/flake/overlays
Expand All @@ -35,19 +34,19 @@
flake = {
inherit (inputs) self;

# Automatic modules, see `./modules/flake/modules.nix`
# Automatic modules, see `./modules/flake/modules/default.nix`
autoModules.enableAll = true;

# Automatic configurations, see `./modules/flake/configurations.nix`
# Automatic configurations, see `./modules/flake/configurations/default.nix`
autoConfigurations.enableAll = true;

# Automatic packages, see `./modules/flake/packages/default.nix`
# Automatic packages, see `./modules/flake/packages/default/default.nix`
autoPackages.enable = true;

# Automatic overlays, see `./modules/flake/overlays/default.nix`
# Automatic overlays, see `./modules/flake/overlays/default/default.nix`
autoOverlays.enable = true;

# Automatic devShells, see `./modules/flake/shells/default.nix`
# Automatic devShells, see `./modules/flake/shells/default/default.nix`
autoDevShells.enable = true;

# Templates
Expand Down
File renamed without changes.
3 changes: 3 additions & 0 deletions hosts/home-manager/__template__/meta.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
system = "x86_64-linux";
}
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

# Zig
zigpkgs.master
inputs.zls-overlay.packages.x86_64-darwin.default
# inputs.zls-overlay.packages.x86_64-darwin.default
];

programs.git = {
Expand Down
3 changes: 3 additions & 0 deletions hosts/nix-darwin/apavel-a01/meta.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
system = "x86_64-darwin";
}
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
nurl

# Mail
# himalaya
himalaya

# Java
graalvm-ce
Expand All @@ -87,7 +87,7 @@

# Zig
zigpkgs.master
inputs.zls-overlay.packages.${pkgs.system}.default
# inputs.zls-overlay.packages.${pkgs.system}.default

# Android
android-tools
Expand Down
15 changes: 15 additions & 0 deletions hosts/nix-darwin/limonka/meta.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
system = "aarch64-darwin";
deploy = {
hostname = "localhost";
sshUser = "pavelatanasov";
user = "pavelatanasov";
sudo = "sudo -u";
sshOpts = [ ];
fastConnection = false;
autoRollback = true;
magicRollback = true;
tempPath = "/Users/pavelatanasov/.deploy-rs";
remoteBuild = true;
};
}
3 changes: 3 additions & 0 deletions hosts/nix-darwin/limontozu/meta.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
system = "x86_64-darwin";
}
File renamed without changes.
3 changes: 3 additions & 0 deletions hosts/nix-on-droid/cheetah/meta.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
system = "aarch64-linux";
}
File renamed without changes.
File renamed without changes.
3 changes: 3 additions & 0 deletions hosts/nixos/__template__/meta.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
system = "x86_64-linux";
}
File renamed without changes.
File renamed without changes.
3 changes: 3 additions & 0 deletions hosts/nixos/homix/meta.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
system = "x86_64-linux";
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
# services.kanidm = { };

age.rekey = {
# TODO: store in `meta`
hostPubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPopSTZ81UyKp9JSljCLp+Syk51zacjh9fLteqxQ6/aB";
# masterIdentities = [ "${inputs.self}/secrets/privkey.age" ];
# storageMode = "local";
Expand Down Expand Up @@ -74,7 +75,10 @@

environment.systemPackages = with pkgs; [
git
neovim
# FIXME: cannot deploy neovim-nightly
# V neovim source
# > error: cannot add path '/nix/store/rhjznh5jdzdkzbnn0fhhvcf9rys0s59d-source' because it lacks a signature by a trusted key
# neovim
];

# NOTE: made with `mkpasswd -m sha-512`
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

home.packages = with pkgs; [
## Core
neovim
# neovim
git
gnupg
pciutils # lspci
Expand Down
File renamed without changes.
Loading

0 comments on commit 9b8f894

Please sign in to comment.