Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Server #16

Merged
merged 4 commits into from
Nov 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions flake.lock

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

25 changes: 9 additions & 16 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,32 +14,25 @@
nixos = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
./hosts/nixos/configuration.nix
vscode-server.nixosModule
({ config, pkgs, ... }: {
services.vscode-server.enable = true;
})
./nixos/configuration.nix
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.homeserver = import ./home-manager/server/home.nix;

# Optionally, use home-manager.extraSpecialArgs to pass
# arguments to home.nix
}
({ config, pkgs, ... }: { services.vscode-server.enable = true; })
];
};
};

# Available through 'home-manager --flake .#your-username@your-hostname'
homeConfigurations = {
# FIXME replace with your username@hostname
"homeserver@nixos" = home-manager.lib.homeManagerConfiguration {
modules = [ ./home-manager/homeserver/home.nix ];
pkgs = nixpkgs.legacyPackages.x86_64-linux;
extraSpecialArgs = { inherit inputs; };
};

"jonathan" = home-manager.lib.homeManagerConfiguration {
modules = [ ./home-manager/mac/home.nix ];
pkgs = nixpkgs.legacyPackages.aarch64-darwin; # Home-manager requires 'pkgs' instance
extraSpecialArgs = { inherit inputs; }; # Pass flake inputs to our config
# > Our main home-manager configuration file <
modules = [ ./home-manager/mac/home.nix ];
};
};
};
Expand Down
21 changes: 15 additions & 6 deletions home-manager/server/home.nix → home-manager/homeserver/home.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# You can update Home Manager without changing this value. See
# the Home Manager release notes for a list of state version
# changes in each release.
home.stateVersion = "22.11";
home.stateVersion = "23.05";

# Let Home Manager install and manage itself.
programs.home-manager.enable = true;
Expand All @@ -38,12 +38,21 @@
gnumake
];

programs.starship = {
enable = true;
enableFishIntegration = true;
enableZshIntegration = false;
settings = {
command_timeout = 1000;
};
};

imports = [
./../common-modules/fish.nix
./../common-modules/direnv.nix
./../common-modules/git.nix
./../common-modules/tmux.nix
./../common-modules/bat.nix
./../../modules/fish.nix
./../../modules/direnv.nix
./../../modules/git.nix
./../../modules/tmux.nix
./../../modules/bat.nix
./local-modules/neovim.nix
];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,7 @@ in
'';
}
papercolor-theme
kanagawa-nvim

{
plugin = material-nvim;
Expand Down
9 changes: 7 additions & 2 deletions nixos/configuration.nix → hosts/nixos/configuration.nix
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
users.users.homeserver = {
isNormalUser = true;
description = "home-server";
extraGroups = [ "networkmanager" "wheel" ];
extraGroups = [ "networkmanager" "wheel" "docker" ];
packages = with pkgs; [
firefox
# thunderbird
Expand Down Expand Up @@ -143,12 +143,17 @@
nix.settings.trusted-users = [ "root" "homeserver" ];
nix.settings.auto-optimise-store = true;

fonts.fonts = with pkgs; [
fonts.packages = with pkgs; [
(nerdfonts.override { fonts = [ "FiraCode" ]; })
];

# Docker
virtualisation.docker = {
enable = true;
};

# Enable tailscale. We manually authenticate when we want with
# "sudo tailscale up". If you don't use tailscale, you should comment
# out or delete all of this.
services.tailscale.enable = true;
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.