diff --git a/flake.nix b/flake.nix index 55619fa..f244c90 100644 --- a/flake.nix +++ b/flake.nix @@ -9,37 +9,6 @@ outputs = { self, nixpkgs, deploy-rs, utils, sops-nix, ... }@inputs: { nixosConfigurations = { - "fsn1-1.mirror.lewd.wtf" = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - specialArgs = { inherit inputs self; }; - modules = [ - sops-nix.nixosModules.sops - ./default.nix - ./hosts/fsn1-1.mirror.lewd.wtf/configuration.nix - ./deployments/mirror/default.nix - ]; - }; - - "master.mirror.lewd.wtf" = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - specialArgs = { inherit inputs self; }; - modules = [ - sops-nix.nixosModules.sops - ./default.nix - ./hosts/master.mirror.lewd.wtf/configuration.nix - ]; - }; - - "mirror.lewd.wtf" = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - specialArgs = { inherit inputs self; }; - modules = [ - sops-nix.nixosModules.sops - ./default.nix - ./hosts/mirror.lewd.wtf/configuration.nix - ]; - }; - "phoenix.lewd.wtf" = nixpkgs.lib.nixosSystem { system = "x86_64-linux"; specialArgs = { inherit inputs self; }; @@ -92,32 +61,6 @@ }; deploy.nodes = { - "master.mirror.lewd.wtf" = { - sshOpts = [ "-p" "222" "-o" "StrictHostKeyChecking=no" ]; - hostname = "master.mirror.lewd.wtf"; - fastConnection = true; - - profiles.system = { - sshUser = "root"; - path = - deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations."master.mirror.lewd.wtf"; - user = "root"; - }; - }; - - "mirror.lewd.wtf" = { - sshOpts = [ "-p" "222" "-o" "StrictHostKeyChecking=no" ]; - hostname = "new.mirror.lewd.wtf"; - fastConnection = true; - - profiles.system = { - sshUser = "root"; - path = - deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations."mirror.lewd.wtf"; - user = "root"; - }; - }; - "phoenix.lewd.wtf" = { sshOpts = [ "-p" "22" "-o" "StrictHostKeyChecking=no" ]; hostname = "phoenix.lewd.wtf"; diff --git a/hosts/master.mirror.lewd.wtf/configuration.nix b/hosts/master.mirror.lewd.wtf/configuration.nix deleted file mode 100644 index d4d6e7e..0000000 --- a/hosts/master.mirror.lewd.wtf/configuration.nix +++ /dev/null @@ -1,25 +0,0 @@ -{ self, config, pkgs, lib, ... }: -let - utils = import ../../util/include.nix { lib = lib; }; - imports = - (utils.includeDir ./mirror_users) ++ - [ - ./hardware-configuration.nix - ./networking.nix - ./sftp_jail.nix - ]; -in -{ - inherit imports; - - networking.hostName = "master"; - networking.domain = "mirror.lewd.wtf"; - - boot.loader.grub = { - enable = true; - efiSupport = false; - devices = [ "/dev/sda" ]; - }; - - system.stateVersion = "22.11"; -} diff --git a/hosts/master.mirror.lewd.wtf/hardware-configuration.nix b/hosts/master.mirror.lewd.wtf/hardware-configuration.nix deleted file mode 100644 index 4e909eb..0000000 --- a/hosts/master.mirror.lewd.wtf/hardware-configuration.nix +++ /dev/null @@ -1,18 +0,0 @@ -{ modulesPath, ... }: -{ - imports = [ (modulesPath + "/profiles/qemu-guest.nix") ]; - boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ]; - boot.kernelModules = [ "kvm-intel" ]; - - fileSystems."/" = { - device = "/dev/disk/by-label/nixos"; - fsType = "ext4"; - }; - - fileSystems."/mnt/data" = { - device = "/dev/disk/by-label/data"; - fsType = "ext4"; - }; - - services.qemuGuest.enable = true; -} diff --git a/hosts/master.mirror.lewd.wtf/mirror_users/abdulsalam.nix b/hosts/master.mirror.lewd.wtf/mirror_users/abdulsalam.nix deleted file mode 100644 index b77ca6c..0000000 --- a/hosts/master.mirror.lewd.wtf/mirror_users/abdulsalam.nix +++ /dev/null @@ -1,16 +0,0 @@ -{ - users.users.abdulsalam = { - group = "sftponly"; - isNormalUser = true; - home = "/sftp_jail/abdulsalam"; - openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIERtfY26/h5xl+bzZm2htR4+Wd879DvZRPHsosFaEqIW gaming@DESKTOP-4ACM3JU" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIE387jL1I99Ws/6BTS/lbiAlDXpyB9zaf08+KWx9U8kd abdulsalam" - ]; - }; - - fileSystems."/sftp_jail/abdulsalam/mirror/saves" = { - device = "/mnt/data/private/nintendo/switch/savegames"; - options = [ "bind" ]; - }; -} diff --git a/hosts/master.mirror.lewd.wtf/mirror_users/archbox.nix b/hosts/master.mirror.lewd.wtf/mirror_users/archbox.nix deleted file mode 100644 index f64d267..0000000 --- a/hosts/master.mirror.lewd.wtf/mirror_users/archbox.nix +++ /dev/null @@ -1,16 +0,0 @@ -{ - users.users.archbox = { - group = "sftponly"; - isNormalUser = true; - home = "/sftp_jail/archbox"; - openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIERtfY26/h5xl+bzZm2htR4+Wd879DvZRPHsosFaEqIW gaming@DESKTOP-4ACM3JU" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJTWN+J6qFf60b58AIEXW/yuDwb7bwoyONKvM10kolWU archbox" - ]; - }; - - fileSystems."/sftp_jail/archbox/mirror/saves" = { - device = "/mnt/data/private/nintendo/switch/savegames"; - options = [ "bind" ]; - }; -} diff --git a/hosts/master.mirror.lewd.wtf/mirror_users/ecks.nix b/hosts/master.mirror.lewd.wtf/mirror_users/ecks.nix deleted file mode 100644 index e53de9b..0000000 --- a/hosts/master.mirror.lewd.wtf/mirror_users/ecks.nix +++ /dev/null @@ -1,20 +0,0 @@ -{ - users.users.ecks = { - group = "sftponly"; - isNormalUser = true; - home = "/sftp_jail/ecks"; - openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIERtfY26/h5xl+bzZm2htR4+Wd879DvZRPHsosFaEqIW gaming@DESKTOP-4ACM3JU" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINczWfNkdndU9bqB2PI1D3glO2CiIaEngXY5FnsodZjt ryusak" - ]; - }; - - fileSystems."/sftp_jail/ecks/mirror/ryusak" = { - device = "/mnt/data/mirror/archive/nintendo/switch/ryusak"; - options = [ "bind" ]; - }; - fileSystems."/sftp_jail/ecks/mirror/shaders" = { - device = "/mnt/data/mirror/archive/nintendo/switch/shaders"; - options = [ "bind" ]; - }; -} diff --git a/hosts/master.mirror.lewd.wtf/mirror_users/mirror.nix b/hosts/master.mirror.lewd.wtf/mirror_users/mirror.nix deleted file mode 100644 index 0b9f8f5..0000000 --- a/hosts/master.mirror.lewd.wtf/mirror_users/mirror.nix +++ /dev/null @@ -1,14 +0,0 @@ -{ - users.users.mirror = { - group = "mirror"; - isNormalUser = true; - openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBGCcaz+17IbyUC/bbhG+m1yYiPa15Uut8GBywVREo1w root@fsn1-1" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOceXaCKbLpRq2LwS3Su6gZjqeIrCzBZfuA7rsKYa4BZ root@ash1-1" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMTUV7UVCWsv0xgLM7rQhGJhCWGX2bgHRG8pHuVEqImZ root@hil1-1" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKbd+qkj1A99nW71Ldip59KI6yNOao0A1l7Mv3GcXaA8 root@hel1-1" - ]; - }; - - users.groups.mirror = {}; -} diff --git a/hosts/master.mirror.lewd.wtf/mirror_users/void.nix b/hosts/master.mirror.lewd.wtf/mirror_users/void.nix deleted file mode 100644 index 918813c..0000000 --- a/hosts/master.mirror.lewd.wtf/mirror_users/void.nix +++ /dev/null @@ -1,18 +0,0 @@ -{ - users.groups.void = {}; - users.users.void = { - group = "void"; - isNormalUser = true; - home = "/home/void"; - openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIERtfY26/h5xl+bzZm2htR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yxcY7ubmvZMVAC8R/8QJvlh3pPQC6BckOvOsMHVMdZrI6yBg1veKoZNCqyRl449QGJU= master@DESKTOP-V6SN4JP" - ]; - }; - - fileSystems."/home/void/mirror/pico" = { - device = "/mnt/data/mirror/archive/picoxr"; - options = [ "bind" ]; - }; -} diff --git a/hosts/master.mirror.lewd.wtf/networking.nix b/hosts/master.mirror.lewd.wtf/networking.nix deleted file mode 100644 index f083d3a..0000000 --- a/hosts/master.mirror.lewd.wtf/networking.nix +++ /dev/null @@ -1,11 +0,0 @@ -{ ... }: -{ - networking.defaultGateway = "192.168.11.1"; - networking.nameservers = [ "1.1.1.1" ]; - networking.interfaces.ens18.ipv4.addresses = [ - { - address = "192.168.11.110"; - prefixLength = 24; - } - ]; -} diff --git a/hosts/master.mirror.lewd.wtf/sftp_jail.nix b/hosts/master.mirror.lewd.wtf/sftp_jail.nix deleted file mode 100644 index 75b883d..0000000 --- a/hosts/master.mirror.lewd.wtf/sftp_jail.nix +++ /dev/null @@ -1,10 +0,0 @@ -{ - services.openssh.extraConfig = '' - Match Group sftponly - ChrootDirectory /sftp_jail - ForceCommand internal-sftp - AllowTcpForwarding no - ''; - - users.groups.sftponly = {}; -} diff --git a/hosts/mirror.lewd.wtf/configuration.nix b/hosts/mirror.lewd.wtf/configuration.nix deleted file mode 100644 index 4d9539a..0000000 --- a/hosts/mirror.lewd.wtf/configuration.nix +++ /dev/null @@ -1,22 +0,0 @@ -{ self, config, pkgs, ... }: -{ - imports = [ - ./hardware-configuration.nix - ./networking.nix - ./mirror/default.nix - ]; - - variables.hostName = "new"; - variables.domain = "mirror.lewd.wtf"; - - networking.hostName = "${config.variables.hostName}"; - networking.domain = "${config.variables.domain}"; - - boot.loader.grub = { - enable = true; - efiSupport = false; - devices = [ "/dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi0" ]; - }; - - system.stateVersion = "22.11"; -} diff --git a/hosts/mirror.lewd.wtf/hardware-configuration.nix b/hosts/mirror.lewd.wtf/hardware-configuration.nix deleted file mode 100644 index f00e811..0000000 --- a/hosts/mirror.lewd.wtf/hardware-configuration.nix +++ /dev/null @@ -1,18 +0,0 @@ -{ modulesPath, ... }: -{ - imports = [ (modulesPath + "/profiles/qemu-guest.nix") ]; - boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ]; - boot.kernelModules = [ "kvm-intel" ]; - - fileSystems."/" = { - device = "/dev/disk/by-label/nixos"; - fsType = "ext4"; - }; - - fileSystems."/var/www/mirror" = { - device = "/dev/disk/by-label/data"; - fsType = "ext4"; - }; - - services.qemuGuest.enable = true; -} diff --git a/hosts/mirror.lewd.wtf/mirror/default.nix b/hosts/mirror.lewd.wtf/mirror/default.nix deleted file mode 100644 index 6d8cd1b..0000000 --- a/hosts/mirror.lewd.wtf/mirror/default.nix +++ /dev/null @@ -1,45 +0,0 @@ -{ config, ... }: -{ - imports = [ - ./xslt_template.nix - ]; - - networking.firewall.allowedTCPPorts = [ 80 443 ]; - - services.nginx = { - enable = true; - virtualHosts."mirror.lewd.wtf" = { - serverName = "${config.variables.hostName}.${config.variables.domain}"; - enableACME = true; - forceSSL = true; - root = "/var/www/mirror/mirror/"; - locations = { - "/" = { - extraConfig = '' - if ($arg_format = "json") { - rewrite ^ /json$request_uri last; - } - autoindex on; - autoindex_format xml; - xslt_stylesheet /etc/nginx/mirror.xslt dirname='$1'; - ''; - }; - "/json/" = { - alias = "/var/www/mirror/mirror/"; - extraConfig = '' - autoindex on; - autoindex_format json; - ''; - }; - "/private/" = { - alias = "/var/www/mirror/private/"; - extraConfig = '' - autoindex off; - ''; - }; - "~ \.xml$" = { - }; - }; - }; - }; -} diff --git a/hosts/mirror.lewd.wtf/mirror/xslt_template.nix b/hosts/mirror.lewd.wtf/mirror/xslt_template.nix deleted file mode 100644 index 7aac3cd..0000000 --- a/hosts/mirror.lewd.wtf/mirror/xslt_template.nix +++ /dev/null @@ -1,8 +0,0 @@ -{ - environment.etc = { - "nginx/mirror.xslt" = { - source = ./xslt_template.xslt; - mode = "0444"; - }; - }; -} diff --git a/hosts/mirror.lewd.wtf/mirror/xslt_template.xslt b/hosts/mirror.lewd.wtf/mirror/xslt_template.xslt deleted file mode 100644 index ca65b77..0000000 --- a/hosts/mirror.lewd.wtf/mirror/xslt_template.xslt +++ /dev/null @@ -1,97 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-

Lewd.wtf Mirror Service

-

Welcome to the mirror service of lewd.wtf! I provide this service free of charge to projects that could benefit from it.

-

Want to get your files hosted here? Please contact me at mirror_request@lewd.wtf and provide details regarding your projects.

-

Proud Sineater and Sin's Cove Hater!

-

If you come here from Sin's Cove, please close this page. This site is hosted by Ecchibitionist, the person you constantly harass.

-

You claim I bullied the original developer of EmuSAK, even though that's a blatant lie (and you know it).

-
-
-

- -

- - - - - - - - - - - - - - - - - - - - - - - B - KiB - MiB - - - - - - - - - -
NameSize
drive_file_move_rtl../
- - - folder - folder_zip - folder_zip - insert_drive_file - - - -
-
- - - -
-
diff --git a/hosts/mirror.lewd.wtf/networking.nix b/hosts/mirror.lewd.wtf/networking.nix deleted file mode 100644 index c430f87..0000000 --- a/hosts/mirror.lewd.wtf/networking.nix +++ /dev/null @@ -1,11 +0,0 @@ -{ ... }: -{ - networking.defaultGateway = "192.168.11.1"; - networking.nameservers = [ "1.1.1.1" ]; - networking.interfaces.ens18.ipv4.addresses = [ - { - address = "192.168.11.107"; - prefixLength = 24; - } - ]; -}