darwin added
This commit is contained in:
BIN
_hosts/.DS_Store
vendored
Normal file
BIN
_hosts/.DS_Store
vendored
Normal file
Binary file not shown.
@@ -5,7 +5,6 @@
|
||||
./hardware-configuration.nix
|
||||
../../nixos-modules
|
||||
inputs.home-manager.nixosModules.default
|
||||
inputs.vscode-server.nixosModules.default
|
||||
];
|
||||
|
||||
# This value determines the NixOS release from which the default
|
||||
@@ -100,6 +99,5 @@
|
||||
enable = true;
|
||||
};
|
||||
|
||||
services.vscode-server.enable = true;
|
||||
virtualisation.docker.enable = true;
|
||||
}
|
||||
|
||||
37
_hosts/cleo-darwin/darwin.nix
Normal file
37
_hosts/cleo-darwin/darwin.nix
Normal file
@@ -0,0 +1,37 @@
|
||||
{ pkgs, ... }: {
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
ids.gids.nixbld = 350;
|
||||
security.pam.services.sudo_local.touchIdAuth = true;
|
||||
|
||||
# 1Password SSH Socket
|
||||
environment.variables.SSH_AUTH_SOCK = "~/Library/Group Containers/2BU8OCWD5C.com.1password/t/agent.sock";
|
||||
|
||||
system.primaryUser = "matthew.bessette";
|
||||
users.users."matthew.bessette" = {
|
||||
name = "matthew.bessette";
|
||||
home = "/Users/matthew.bessette";
|
||||
};
|
||||
|
||||
# Homebrew for Casks and specific binaries
|
||||
homebrew = {
|
||||
enable = true;
|
||||
onActivation.cleanup = "uninstall";
|
||||
taps = [ "bufbuild/buf" "jacobjohansen/tap" ];
|
||||
brews = [ "jacobjohansen/tap/rds-auth-proxy"];
|
||||
casks = [
|
||||
"android-commandlinetools"
|
||||
"android-platform-tools"
|
||||
"bruno"
|
||||
"kopiaui"
|
||||
"libreoffice"
|
||||
"signal"
|
||||
"spotify"
|
||||
"yubico-yubikey-manager"
|
||||
"visual-studio-code"
|
||||
"zoom"
|
||||
];
|
||||
};
|
||||
|
||||
nix.settings.experimental-features = "nix-command flakes";
|
||||
system.stateVersion = 4;
|
||||
}
|
||||
77
_hosts/cleo-darwin/home.nix
Normal file
77
_hosts/cleo-darwin/home.nix
Normal file
@@ -0,0 +1,77 @@
|
||||
{ pkgs, ... }: {
|
||||
home.stateVersion = "23.11";
|
||||
|
||||
home.username = "matthew.bessette";
|
||||
home.homeDirectory = "/Users/matthew.bessette";
|
||||
|
||||
home.packages = with pkgs; [
|
||||
# Dev Specs
|
||||
python3
|
||||
pipenv
|
||||
nodejs_22
|
||||
yarn
|
||||
jdk17
|
||||
|
||||
# DB
|
||||
postgresql_16 # pgdump/restore
|
||||
|
||||
# CLI Tools from your Brewfile
|
||||
xz
|
||||
ffmpeg
|
||||
earthly
|
||||
awscli2
|
||||
buf
|
||||
];
|
||||
|
||||
# Managed VS Code Extensions (The "Clean" Way)
|
||||
programs.vscode = {
|
||||
enable = true;
|
||||
profiles.default = {
|
||||
extensions = with pkgs.vscode-extensions; [
|
||||
ms-python.python
|
||||
ms-python.vscode-pylance
|
||||
ms-python.debugpy
|
||||
hashicorp.terraform
|
||||
esbenp.prettier-vscode
|
||||
dbaeumer.vscode-eslint
|
||||
eamodio.gitlens
|
||||
redhat.vscode-xml
|
||||
mechatroner.rainbow-csv
|
||||
bbenoist.nix
|
||||
# Note: Some niche extensions might need to be installed manually in VS Code
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
# Automatically load the 1Password agent in your shell
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
enableCompletion = true;
|
||||
autosuggestion.enable = true;
|
||||
syntaxHighlighting.enable = true;
|
||||
oh-my-zsh.enable = true;
|
||||
oh-my-zsh.theme = "robbyrussell";
|
||||
oh-my-zsh.plugins = [
|
||||
"git"
|
||||
"npm"
|
||||
];
|
||||
|
||||
initContent = ''
|
||||
export SSH_AUTH_SOCK=~/Library/Group\ Containers/2BU8OCWD5C.com.1password/t/agent.sock
|
||||
'';
|
||||
|
||||
shellAliases = {
|
||||
ll = "ls -l";
|
||||
update = "sudo darwin-rebuild switch --flake ~/nixos#cleo-darwin";
|
||||
laws = "aws --endpoint=http://localhost:4566";
|
||||
dev = "nix develop -c $SHELL";
|
||||
nixos = "code ~/nixos";
|
||||
};
|
||||
};
|
||||
|
||||
home.sessionVariables = {
|
||||
# Points to the Homebrew location mentioned in your caveat
|
||||
ANDROID_HOME = "/opt/homebrew/share/android-commandlinetools";
|
||||
JAVA_HOME = "${pkgs.jdk17}";
|
||||
};
|
||||
}
|
||||
139
flake.lock
generated
139
flake.lock
generated
@@ -1,19 +1,39 @@
|
||||
{
|
||||
"nodes": {
|
||||
"darwin": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1771992996,
|
||||
"narHash": "sha256-Y/ijH/unOPxzUicbla6yT/14RJgubUWnY2I2A6Ast2Q=",
|
||||
"owner": "lnl7",
|
||||
"repo": "nix-darwin",
|
||||
"rev": "3bfa436c1975674ca465ce34586467be301ff509",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "lnl7",
|
||||
"ref": "master",
|
||||
"repo": "nix-darwin",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"firefox-addons": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"dir": "pkgs/firefox-addons",
|
||||
"lastModified": 1742097805,
|
||||
"narHash": "sha256-N3/7llBZ93Itf7ndnNtEm7lPoMqSC57B/PNaMB6cL1Q=",
|
||||
"lastModified": 1771992172,
|
||||
"narHash": "sha256-XdaMLD1Gjev6i3tBeVFLORc1uLGNg9XbUf+LmxpGIYo=",
|
||||
"owner": "rycee",
|
||||
"repo": "nur-expressions",
|
||||
"rev": "5a0ac85616aa6b166ea715a41bc1255bb802b189",
|
||||
"rev": "0002367df8f1b5d8089eaf0314ddc4afe73b271a",
|
||||
"type": "gitlab"
|
||||
},
|
||||
"original": {
|
||||
@@ -26,11 +46,11 @@
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1733328505,
|
||||
"narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=",
|
||||
"lastModified": 1767039857,
|
||||
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec",
|
||||
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -39,39 +59,6 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"locked": {
|
||||
"lastModified": 1629284811,
|
||||
"narHash": "sha256-JHgasjPR0/J1J3DRm4KxM4zTyAj4IOJY8vIl75v/kPI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "c5d161cc0af116a2e17f54316f0bf43f0819785c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils_2": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1681202837,
|
||||
"narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "cfacdce06f30d2b68473a46042957675eebb3401",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
@@ -79,11 +66,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1741955947,
|
||||
"narHash": "sha256-2lbURKclgKqBNm7hVRtWh0A7NrdsibD0EaWhahUVhhY=",
|
||||
"lastModified": 1771851181,
|
||||
"narHash": "sha256-gFgE6mGUftwseV3DUENMb0k0EiHd739lZexPo5O/sdQ=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "4e12151c9e014e2449e0beca2c0e9534b96a26b4",
|
||||
"rev": "9a4b494b1aa1b93d8edf167f46dc8e0c0011280c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -94,11 +81,11 @@
|
||||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1741792691,
|
||||
"narHash": "sha256-f0BVt1/cvA0DQ/q3rB+HY4g4tKksd03ZkzI4xehC2Ew=",
|
||||
"lastModified": 1771969195,
|
||||
"narHash": "sha256-qwcDBtrRvJbrrnv1lf/pREQi8t2hWZxVAyeMo7/E9sw=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "e1f12151258b12c567f456d8248e4694e9390613",
|
||||
"rev": "41c6b421bdc301b2624486e11905c9af7b8ec68e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -114,11 +101,11 @@
|
||||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1741870048,
|
||||
"narHash": "sha256-odXRdNZGdXg1LmwlAeWL85kgy/FVHsgKlDwrvbR2BsU=",
|
||||
"lastModified": 1771563879,
|
||||
"narHash": "sha256-vA5hocvdGhr+jfBN7A7ogeZqIz2qx01EixXwdVsQcnE=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NixOS-WSL",
|
||||
"rev": "5d76001e33ee19644a598ad80e7318ab0957b122",
|
||||
"rev": "379d20c55f552e91fb9f3f0382e4a97d3f452943",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -130,27 +117,27 @@
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1740865531,
|
||||
"narHash": "sha256-h00vGIh/jxcGl8aWdfnVRD74KuLpyY3mZgMFMy7iKIc=",
|
||||
"lastModified": 1770019141,
|
||||
"narHash": "sha256-VKS4ZLNx4PNrABoB0L8KUpc1fE7CLpQXQs985tGfaCU=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "5ef6c425980847c78a80d759abc476e941a9bf42",
|
||||
"rev": "cb369ef2efd432b3cdf8622b0ffc0a97a02f3137",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-24.11",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1741851582,
|
||||
"narHash": "sha256-cPfs8qMccim2RBgtKGF+x9IBCduRvd/N5F4nYpU0TVE=",
|
||||
"lastModified": 1771848320,
|
||||
"narHash": "sha256-0MAd+0mun3K/Ns8JATeHT1sX28faLII5hVLq0L3BdZU=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "6607cf789e541e7873d40d3a8f7815ea92204f32",
|
||||
"rev": "2fc6539b481e1d2569f25f8799236694180c0993",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -162,48 +149,12 @@
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"darwin": "darwin",
|
||||
"firefox-addons": "firefox-addons",
|
||||
"home-manager": "home-manager",
|
||||
"nixos-hardware": "nixos-hardware",
|
||||
"nixos-wsl": "nixos-wsl",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"vscode-server": "vscode-server"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"vscode-server": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils_2",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1729422940,
|
||||
"narHash": "sha256-DlvJv33ml5UTKgu4b0HauOfFIoDx6QXtbqUF3vWeRCY=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nixos-vscode-server",
|
||||
"rev": "8b6db451de46ecf9b4ab3d01ef76e59957ff549f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "nixos-vscode-server",
|
||||
"type": "github"
|
||||
"nixpkgs": "nixpkgs_2"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
22
flake.nix
22
flake.nix
@@ -6,10 +6,8 @@
|
||||
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
||||
nixos-wsl.url = "github:nix-community/NixOS-WSL/main";
|
||||
|
||||
vscode-server = {
|
||||
url = "github:nix-community/nixos-vscode-server";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
darwin.url = "github:lnl7/nix-darwin/master";
|
||||
darwin.inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager";
|
||||
@@ -23,7 +21,7 @@
|
||||
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, nixos-hardware, nixos-wsl, ... }@inputs:
|
||||
outputs = { self, darwin,nixpkgs, nixos-hardware, nixos-wsl, home-manager, ... }@inputs:
|
||||
let
|
||||
system = "x86_64-linux";
|
||||
pkgs = import nixpkgs {
|
||||
@@ -74,6 +72,20 @@
|
||||
];
|
||||
};
|
||||
|
||||
darwinConfigurations.cleo-darwin = darwin.lib.darwinSystem {
|
||||
specialArgs = { inherit system; inherit inputs; };
|
||||
system = "aarch64-darwin";
|
||||
modules = [
|
||||
./_hosts/cleo-darwin/darwin.nix
|
||||
home-manager.darwinModules.home-manager
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users."matthew.bessette" = import ./_hosts/cleo-darwin/home.nix;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
homeManagerModules.default = "./nixos-modules/home-manager";
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user