From fc226a3da66610f8037ac3acd046ea57f5f2c157 Mon Sep 17 00:00:00 2001 From: Emelie Graven Date: Mon, 15 Nov 2021 16:34:06 +0100 Subject: [PATCH] disable public registration on grondahl, remove nixos-testbed --- config/hosts/grondahl/services/synapse.nix | 2 +- config/hosts/nixos-testbed/configuration.nix | 49 ------------------- .../nixos-testbed/hardware-configuration.nix | 26 ---------- .../nixos-testbed/services/nextcloud.nix | 9 ---- config/sources/nix/sources.json | 18 +++---- 5 files changed, 10 insertions(+), 94 deletions(-) delete mode 100644 config/hosts/nixos-testbed/configuration.nix delete mode 100644 config/hosts/nixos-testbed/hardware-configuration.nix delete mode 100644 config/hosts/nixos-testbed/services/nextcloud.nix diff --git a/config/hosts/grondahl/services/synapse.nix b/config/hosts/grondahl/services/synapse.nix index 9becf4e..59471ab 100644 --- a/config/hosts/grondahl/services/synapse.nix +++ b/config/hosts/grondahl/services/synapse.nix @@ -4,7 +4,7 @@ services.matrix-synapse = { enable = true; server_name = "anarkafem.dev"; - enable_registration = true; + enable_registration = false; registration_shared_secret = builtins.toString config.secrets.files.synapse_registration_shared_secret.file; turn_shared_secret = builtins.toString config.secrets.files.turn_shared_secret.file; max_upload_size = "20M"; diff --git a/config/hosts/nixos-testbed/configuration.nix b/config/hosts/nixos-testbed/configuration.nix deleted file mode 100644 index 72b774f..0000000 --- a/config/hosts/nixos-testbed/configuration.nix +++ /dev/null @@ -1,49 +0,0 @@ -{ config, pkgs, lib, ... }: - -{ - imports = [ - ./hardware-configuration.nix - ../../common/services/ssh.nix - ]; - - boot.loader.grub.enable = true; - boot.loader.grub.version = 2; - boot.loader.grub.device = "/dev/sda"; - networking.hostName = "nixos-testbed"; - time.timeZone = "Europe/Copenhagen"; - networking.useDHCP = false; - networking.interfaces.ens3.useDHCP = true; - networking.interfaces.ens3.ipv6.addresses = [ { address = "2a01:4f9:c011:50e2::1"; prefixLength = 64; } ]; - networking.defaultGateway6 = { address = "fe80::1"; interface = "ens3"; }; - - users.users.emelie = { - isNormalUser = true; - extraGroups = [ "wheel" ]; - openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICO4LyBsW1YuUA6i3EL/IZhchSvk7reO4qgRmR/tdQPU emelie@flap" - ]; - }; - - security.sudo.wheelNeedsPassword = false; - - environment.systemPackages = with pkgs; [ - vim - htop - iotop - dig - ]; - - nix = { - autoOptimiseStore = true; - trustedUsers = [ - "root" - "@wheel" - ]; - }; - - # Use hetzner firewall instead - networking.firewall.enable = false; - - system.stateVersion = "21.05"; - -} diff --git a/config/hosts/nixos-testbed/hardware-configuration.nix b/config/hosts/nixos-testbed/hardware-configuration.nix deleted file mode 100644 index 27c490b..0000000 --- a/config/hosts/nixos-testbed/hardware-configuration.nix +++ /dev/null @@ -1,26 +0,0 @@ -# Do not modify this file! It was generated by ‘nixos-generate-config’ -# and may be overwritten by future invocations. Please make changes -# to /etc/nixos/configuration.nix instead. -{ config, lib, pkgs, modulesPath, ... }: - -{ - imports = - [ (modulesPath + "/profiles/qemu-guest.nix") - (modulesPath + "/profiles/minimal.nix") - ]; - - boot.initrd.availableKernelModules = [ "ata_piix" "virtio_pci" "virtio_scsi" "xhci_pci" "sd_mod" "sr_mod" ]; - boot.initrd.kernelModules = [ ]; - boot.kernelModules = [ ]; - boot.extraModulePackages = [ ]; - - fileSystems."/" = - { device = "/dev/disk/by-uuid/b5f08f96-c7aa-4c02-86a2-15cfe4134f4d"; - fsType = "ext4"; - }; - - swapDevices = - [ { device = "/dev/disk/by-uuid/f36e61f8-337f-4b77-bd63-9b1d0146d73d"; } - ]; - -} diff --git a/config/hosts/nixos-testbed/services/nextcloud.nix b/config/hosts/nixos-testbed/services/nextcloud.nix deleted file mode 100644 index a0bc602..0000000 --- a/config/hosts/nixos-testbed/services/nextcloud.nix +++ /dev/null @@ -1,9 +0,0 @@ -{ ... }: { - services.nextcloud = { - enable = true; - https = true; - webfinger = true; - hostname = "cloud-test.graven.dev"; - - }; -} diff --git a/config/sources/nix/sources.json b/config/sources/nix/sources.json index 80c9122..62a9554 100644 --- a/config/sources/nix/sources.json +++ b/config/sources/nix/sources.json @@ -5,10 +5,10 @@ "homepage": "https://github.com/nmattia/niv", "owner": "nmattia", "repo": "niv", - "rev": "65a61b147f307d24bfd0a5cd56ce7d7b7cc61d2e", - "sha256": "17mirpsx5wyw262fpsd6n6m47jcgw8k2bwcp1iwdnrlzy4dhcgqh", + "rev": "5830a4dd348d77e39a0f3c4c762ff2663b602d4c", + "sha256": "1d3lsrqvci4qz2hwjrcnd8h5vfkg8aypq3sjd4g3izbc8frwz5sm", "type": "tarball", - "url": "https://github.com/nmattia/niv/archive/65a61b147f307d24bfd0a5cd56ce7d7b7cc61d2e.tar.gz", + "url": "https://github.com/nmattia/niv/archive/5830a4dd348d77e39a0f3c4c762ff2663b602d4c.tar.gz", "url_template": "https://github.com///archive/.tar.gz" }, "nixos-hardware": { @@ -17,10 +17,10 @@ "homepage": "", "owner": "NixOS", "repo": "nixos-hardware", - "rev": "3aabf78bfcae62f5f99474f2ebbbe418f1c6e54f", - "sha256": "10g240brgjz7qi20adwajxwqrqb5zxc79ii1mc20fasgqlf2a8sx", + "rev": "4045d5f43aff4440661d8912fc6e373188d15b5b", + "sha256": "1f07p7awpxwg8f9ps5ncvnpkh9ny3aj2n28gqqhafdk9i6f9zkfi", "type": "tarball", - "url": "https://github.com/NixOS/nixos-hardware/archive/3aabf78bfcae62f5f99474f2ebbbe418f1c6e54f.tar.gz", + "url": "https://github.com/NixOS/nixos-hardware/archive/4045d5f43aff4440661d8912fc6e373188d15b5b.tar.gz", "url_template": "https://github.com///archive/.tar.gz" }, "nixpkgs": { @@ -29,10 +29,10 @@ "homepage": "", "owner": "NixOS", "repo": "nixpkgs", - "rev": "3ef1d2a9602c18f8742e1fb63d5ae9867092e3d6", - "sha256": "0yicccl89rfa5nk4ic46ydihvzsw1phzsypnlzmzrdnwsxi3r9d4", + "rev": "0b239a479cd2c6246195f76244d0939845f82634", + "sha256": "0p1x6zmsh5yfz0xrkvi9nrymznnaz8l46srib271bzmcbbd2fb21", "type": "tarball", - "url": "https://github.com/NixOS/nixpkgs/archive/3ef1d2a9602c18f8742e1fb63d5ae9867092e3d6.tar.gz", + "url": "https://github.com/NixOS/nixpkgs/archive/0b239a479cd2c6246195f76244d0939845f82634.tar.gz", "url_template": "https://github.com///archive/.tar.gz" }, "nixus": {