Add stagirite WSL configs
This commit is contained in:
parent
4630c8add7
commit
beb7245758
83
flake.lock
generated
83
flake.lock
generated
@ -1,19 +1,69 @@
|
||||
{
|
||||
"nodes": {
|
||||
"nixpkgs": {
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1669052418,
|
||||
"narHash": "sha256-M1I4BKXBQm2gey1tScemEh5TpHHE3gKptL7BpWUvL8s=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "20fc948445a6c22d4e8d5178e9a6bc6e1f5417c8",
|
||||
"lastModified": 1650374568,
|
||||
"narHash": "sha256-Z+s0J8/r907g149rllvwhb4pKi8Wam5ij0st8PwAh+E=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "b4a34015c698c7793d592d66adbab377907a2be8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"locked": {
|
||||
"lastModified": 1667395993,
|
||||
"narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixos-wsl": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1669627414,
|
||||
"narHash": "sha256-9k62MwUC+poOn1wS3Yp6sE0nt7gzOtE1iXGJ0F/5bis=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NixOS-WSL",
|
||||
"rev": "2bb34d04bc866ae4cecd5d23d7fda36bb4832f60",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "NixOS-WSL",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1667653703,
|
||||
"narHash": "sha256-Xow4vx52/g5zkhlgZnMEm/TEXsj+13jTPCc2jIhW1xU=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "20fc948445a6c22d4e8d5178e9a6bc6e1f5417c8",
|
||||
"rev": "f09ad462c5a121d0239fde645aacb2221553a217",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "nixpkgs",
|
||||
"ref": "nixos-22.05",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"nixpkgs-empyrean": {
|
||||
@ -32,9 +82,26 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1669052418,
|
||||
"narHash": "sha256-M1I4BKXBQm2gey1tScemEh5TpHHE3gKptL7BpWUvL8s=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "20fc948445a6c22d4e8d5178e9a6bc6e1f5417c8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "20fc948445a6c22d4e8d5178e9a6bc6e1f5417c8",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixos-wsl": "nixos-wsl",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"nixpkgs-empyrean": "nixpkgs-empyrean"
|
||||
}
|
||||
}
|
||||
|
@ -2,9 +2,10 @@
|
||||
inputs = {
|
||||
nixpkgs.url = "github:NixOS/nixpkgs?rev=20fc948445a6c22d4e8d5178e9a6bc6e1f5417c8";
|
||||
nixpkgs-empyrean.url = "github:NixOS/nixpkgs?rev=2ebb6c1e5ae402ba35cca5eec58385e5f1adea04";
|
||||
nixos-wsl.url = github:nix-community/NixOS-WSL;
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, nixpkgs-empyrean }: {
|
||||
outputs = { self, nixpkgs, nixpkgs-empyrean, nixos-wsl }@attrs: {
|
||||
nixosConfigurations.catacomb = nixpkgs.lib.nixosSystem {
|
||||
system = "aarch64-linux";
|
||||
modules = [ ./machine/catacomb ];
|
||||
@ -13,5 +14,10 @@
|
||||
system = "x86_64-linux";
|
||||
modules = [ ./machine/empyrean ];
|
||||
};
|
||||
nixosConfigurations.stagirite = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = attrs;
|
||||
modules = [ ./machine/stagirite ];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
70
machine/stagirite/default.nix
Normal file
70
machine/stagirite/default.nix
Normal file
@ -0,0 +1,70 @@
|
||||
{ lib, pkgs, config, modulesPath, nixos-wsl, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
wp = { addr = "localhost"; port = 4567; };
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
"${modulesPath}/profiles/minimal.nix"
|
||||
|
||||
nixos-wsl.nixosModules.wsl
|
||||
];
|
||||
|
||||
wsl = {
|
||||
enable = true;
|
||||
wslConf.automount.root = "/mnt";
|
||||
defaultUser = "nixos";
|
||||
startMenuLaunchers = true;
|
||||
};
|
||||
|
||||
system.stateVersion = "21.11";
|
||||
|
||||
networking.hostName = "stagirite";
|
||||
|
||||
fileSystems.winssh = {
|
||||
device = "C:/Users/tvb/.ssh";
|
||||
fsType = "drvfs";
|
||||
options = [ "ro" "noatime" "uid=1000" "gid=100" "case=off" "umask=0077" "fmask=0177" "metadata" ];
|
||||
depends = [ "/" ];
|
||||
mountPoint = "/home/nixos/.ssh";
|
||||
};
|
||||
|
||||
documentation.enable = true;
|
||||
documentation.man.enable = true;
|
||||
documentation.dev.enable = true;
|
||||
|
||||
# Enable nix flakes
|
||||
nix.package = pkgs.nixFlakes;
|
||||
nix.extraOptions = ''
|
||||
experimental-features = nix-command flakes
|
||||
'';
|
||||
|
||||
environment.systemPackages =
|
||||
[
|
||||
pkgs.vim pkgs.git
|
||||
pkgs.nmap
|
||||
(pkgs.python3.withPackages (pypkgs: [ pypkgs.poetry ]))
|
||||
pkgs.htop pkgs.wget
|
||||
pkgs.gcc
|
||||
];
|
||||
environment.variables = {
|
||||
EDITOR = "vim";
|
||||
};
|
||||
|
||||
#services.code-server.enable = true;
|
||||
#services.code-server.extraPackages = [ pkgs.bashInteractive ];
|
||||
|
||||
services.openssh.enable = true;
|
||||
|
||||
#services.wordpress.webserver = "nginx";
|
||||
#services.wordpress.sites.${wp.addr} = {
|
||||
# extraConfig = ''
|
||||
# define('WPSITEURL','http://${wp.addr}:${toString wp.port}/');
|
||||
# define('WPHOME','http://${wp.addr}:${toString wp.port}/');
|
||||
# '';
|
||||
#};
|
||||
#services.nginx.virtualHosts.${wp.addr} = {
|
||||
# listen = [ wp ];
|
||||
#};
|
||||
}
|
Loading…
Reference in New Issue
Block a user