Initial commit
Some checks failed
CI / check (push) Has been cancelled
CI / ida (push) Has been cancelled
CI / cpt (push) Has been cancelled
CI / build-nixos (ena) (push) Has been cancelled
CI / build-nixos (hako) (push) Has been cancelled
CI / build-nixos (kazusa) (push) Has been cancelled
CI / build-nixos (mizuki) (push) Has been cancelled
Some checks failed
CI / check (push) Has been cancelled
CI / ida (push) Has been cancelled
CI / cpt (push) Has been cancelled
CI / build-nixos (ena) (push) Has been cancelled
CI / build-nixos (hako) (push) Has been cancelled
CI / build-nixos (kazusa) (push) Has been cancelled
CI / build-nixos (mizuki) (push) Has been cancelled
This commit is contained in:
commit
70284509f3
144 changed files with 7061 additions and 0 deletions
103
hosts/server/kazusa/configuration.nix
Normal file
103
hosts/server/kazusa/configuration.nix
Normal file
|
|
@ -0,0 +1,103 @@
|
|||
{
|
||||
pkgs,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
"${inputs.self}/modules/nixos/base"
|
||||
"${inputs.self}/modules/nixos/features/boot.nix"
|
||||
"${inputs.self}/modules/nixos/features/ssh.nix"
|
||||
"${inputs.self}/modules/nixos/features/docker.nix"
|
||||
./services/mailserver.nix
|
||||
./services/caddy.nix
|
||||
];
|
||||
|
||||
# Override shared boot.nix for Legacy BIOS
|
||||
boot.loader.grub.enableCryptodisk = lib.mkForce false;
|
||||
|
||||
services.netbird.enable = true;
|
||||
|
||||
users.users.imnyang.openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOHP3Z+AYrRh9f8TYyqChKfeyNm3lOe0F75AwRHTTaxD imnyang@kazusa"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIrpjEYOBx7LTGb7QsPrmPBboqyTUNm/e+4+yqWruljv imnyang@natsu"
|
||||
];
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
eza
|
||||
neovim
|
||||
nil
|
||||
nixd
|
||||
bun
|
||||
];
|
||||
|
||||
boot.kernel.sysctl = {
|
||||
"net.ipv4.ip_forward" = 1;
|
||||
"net.ipv6.conf.all.forwarding" = 1;
|
||||
};
|
||||
|
||||
programs.git.config = {
|
||||
safe.directory = "*";
|
||||
};
|
||||
|
||||
networking = {
|
||||
hostName = "kazusa";
|
||||
domain = "icn.mizuki.guru";
|
||||
nameservers = [
|
||||
"1.1.1.1"
|
||||
"1.0.0.1"
|
||||
"9.9.9.9"
|
||||
"149.112.112.112"
|
||||
];
|
||||
useDHCP = false;
|
||||
dhcpcd.enable = false;
|
||||
interfaces.ens18 = {
|
||||
ipv4.addresses = [
|
||||
{
|
||||
address = "82.21.82.30";
|
||||
prefixLength = 24;
|
||||
}
|
||||
];
|
||||
};
|
||||
defaultGateway = {
|
||||
address = "82.21.82.1";
|
||||
interface = "ens18";
|
||||
};
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
22
|
||||
80
|
||||
443
|
||||
];
|
||||
|
||||
systemd.services.gnaynmi = {
|
||||
description = "discord bot";
|
||||
after = [ "network-online.target" ];
|
||||
wants = [ "network-online.target" ];
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
|
||||
serviceConfig = {
|
||||
Type = "simple";
|
||||
User = "imnyang";
|
||||
WorkingDirectory = "/home/imnyang/gnaynmi";
|
||||
EnvironmentFile = "/home/imnyang/gnaynmi/.env";
|
||||
ExecStart = "${pkgs.bun}/bin/bun run src/index.ts";
|
||||
Restart = "always";
|
||||
RestartSec = 5;
|
||||
};
|
||||
|
||||
path = [
|
||||
pkgs.bun
|
||||
pkgs.stdenv.cc.cc.lib
|
||||
];
|
||||
environment = {
|
||||
LD_LIBRARY_PATH = "${pkgs.stdenv.cc.cc.lib}/lib";
|
||||
};
|
||||
};
|
||||
|
||||
services.qemuGuest.enable = true;
|
||||
|
||||
system.stateVersion = "26.05";
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue