modified: README.md
modified: flake.nix modified: home/README.md modified: home/ssh.nix modified: hosts/README.md modified: hosts/desktop/README.md modified: hosts/desktop/configuration.nix new file: hosts/nixos-lxc/README.md new file: hosts/nixos-lxc/configuration.nix renamed: modules/wsl/default.nix -> hosts/nixos-lxc/default.nix modified: hosts/server/README.md modified: hosts/server/configuration.nix modified: hosts/virtualbox/README.md modified: hosts/virtualbox/configuration.nix modified: hosts/virtualbox/hardware-configuration.nix modified: hosts/wsl/README.md modified: hosts/wsl/configuration.nix modified: lib/README.md modified: lib/hosts.nix modified: lib/mkHost.nix modified: modules/README.md modified: modules/core/README.md modified: modules/core/core.nix modified: modules/core/users.nix modified: modules/desktop/README.md modified: modules/desktop/de/README.md modified: modules/desktop/wm/README.md modified: modules/desktop/wm/default.nix modified: modules/drivers/README.md modified: modules/drivers/amdgpu.nix modified: modules/server/README.md modified: modules/server/default.nix new file: modules/server/firewall.nix modified: modules/server/pkg.nix modified: modules/server/ssh.nix modified: modules/server/virtualbox-guest.nix deleted: modules/wsl/README.md deleted: modules/wsl/configuration.nix modified: overlays/README.md modified: profiles/README.md modified: profiles/desktop.nix new file: profiles/lxc.nix modified: profiles/wsl.nix modified: secrets/README.md modified: secrets/users/README.md 添加了pve-lxc的配置文件 删除了wsl的配置文件
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# 🗄️ modules/server
|
||||
# 🗄️ modules/server
|
||||
|
||||
服务器专用模块。
|
||||
|
||||
@@ -7,8 +7,10 @@
|
||||
🗄️ modules/server
|
||||
├─ 📦 default.nix # 聚合入口
|
||||
├─ 📦 pkg.nix # 服务器常用软件包
|
||||
├─ 🔥 firewall.nix # 防火墙默认策略
|
||||
├─ 🔐 ssh.nix # OpenSSH 参数
|
||||
├─ 🐳 docker.nix # Docker 与清理策略
|
||||
├─ 📦 virtualbox-guest.nix # VirtualBox Guest 增强配置
|
||||
└─ 🧠 vscode-server.nix # VS Code Server 模块
|
||||
```
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
{
|
||||
imports = [
|
||||
./pkg.nix
|
||||
./firewall.nix
|
||||
./docker.nix
|
||||
./ssh.nix
|
||||
];
|
||||
|
||||
4
modules/server/firewall.nix
Normal file
4
modules/server/firewall.nix
Normal file
@@ -0,0 +1,4 @@
|
||||
{ lib, ... }:
|
||||
{
|
||||
networking.firewall.enable = lib.mkDefault true;
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
environment.systemPackages = with pkgs; [
|
||||
jq
|
||||
|
||||
];
|
||||
}
|
||||
|
||||
@@ -2,13 +2,13 @@
|
||||
{
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
settings = {
|
||||
PasswordAuthentication = false;
|
||||
KbdInteractiveAuthentication = false;
|
||||
PermitRootLogin = "no";
|
||||
X11Forwarding = false;
|
||||
};
|
||||
openFirewall = true;
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{ ... }:
|
||||
{
|
||||
# virtualbox-guest
|
||||
# VirtualBox Guest 增强支持
|
||||
virtualisation.virtualbox.guest.enable = true;
|
||||
virtualisation.virtualbox.guest.dragAndDrop = true;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user