summaryrefslogtreecommitdiff
path: root/hostnix/elmo/configuration.nix
diff options
context:
space:
mode:
Diffstat (limited to 'hostnix/elmo/configuration.nix')
-rw-r--r--hostnix/elmo/configuration.nix78
1 files changed, 42 insertions, 36 deletions
diff --git a/hostnix/elmo/configuration.nix b/hostnix/elmo/configuration.nix
index 3ab9922..bc9b84a 100644
--- a/hostnix/elmo/configuration.nix
+++ b/hostnix/elmo/configuration.nix
@@ -1,68 +1,74 @@
-# Edit this configuration file to define what should be installed on
-# your system. Help is available in the configuration.nix(5) man page
-# and in the NixOS manual (accessible by running ‘nixos-help’).
-
{ config, pkgs, ... }:
{
- imports =
- [ # Include the results of the hardware scan.
- ./desktop.nix
- ./hardware-configuration.nix
- ./system.nix
- ];
+ imports = [
+ ./dyndns.nix
+ ./hardware-configuration.nix
+ ./home-assistant.nix
+ ./oidc.nix
+ ./privacy-frontends.nix
+ ./syncthing.nix
+ ./system.nix
+ ];
+
+ nix.settings.experimental-features = [ "nix-command" "flakes" ];
+
+ security.acme.acceptTerms = true;
+ security.acme.defaults.email = "hostmaster@mou.fo";
+ # TODO switch to production certs
+ security.acme.defaults.server = "https://acme-staging-v02.api.letsencrypt.org/directory";
security.sudo.wheelNeedsPassword = false;
- # Define a user account. Don't forget to set a password with ‘passwd’.
users.users.joe = {
isNormalUser = true;
description = "Joe Mou";
- extraGroups = [ "networkmanager" "wheel" ];
+ extraGroups = [ "networkmanager" "wheel" "syncthing" ];
packages = with pkgs; [
- firefox
- # thunderbird
+ jq
+ sqlite-interactive
];
openssh.authorizedKeys.keys = [
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDHcqQDnH0LcUWFV+cd9aABfM55+72UAn1ZY5x5bHwPL4IEgT1nagbi1X3FwCJkh2rEcDsHl4FflcNfh+IyU2VyuQfRIXl7CKP040ovXmPVzgU8JiEDrrRebpZ7aHCKk+4Q6cJ8dzAI1sRogVyYrV0hLB4yeMnVexkIcsQMt5pXQ1zodlzHfW1W7OWQDbKjIyh4pv1KJ/IIjiBIt7l+OCqi7wZK4ubmxyMhmZx1xpRC5mz2/29Mpt+1VgCmxC7Hv1SG7yu+U0s4eJ3kbzFKNcZ/bCYqFxK48dT66qhS3qZFg09omumG8IbEUcx+WqM1V7WhiJYig9x5ovmMToQXTJ5uxLtcovnxO/53IgwV7INvmr8+NhD+LlkQfSjjUAW09bhVj9sKIW2bbrIxlOT8z6CQY9zGXNXi8u1oxPt3Q7d3rMxoWhWnr2l3Ok7OIkWooOK3e0NdhgIAxZKlYJAmIYaX391sGTyiuwUy96mg5JcYsLYMfkEg/Sv+2vQp8kkvB0E= joe@sparky"
];
};
- # Allow unfree packages
nixpkgs.config.allowUnfree = true;
- # List packages installed in system profile. To search, run:
- # $ nix search wget
environment.systemPackages = with pkgs; [
- # vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
- # wget
+ dig
+ file
+ gitFull
+ tmux
+ tree
];
- # Some programs need SUID wrappers, can be configured further or are
- # started in user sessions.
- # programs.mtr.enable = true;
- # programs.gnupg.agent = {
- # enable = true;
- # enableSSHSupport = true;
- # };
-
- # List services that you want to enable:
+ programs.vim.defaultEditor = true;
+ programs.nano.enable = false;
- # Enable the OpenSSH daemon.
services.openssh.enable = true;
- # Open ports in the firewall.
- # networking.firewall.allowedTCPPorts = [ ... ];
- # networking.firewall.allowedUDPPorts = [ ... ];
- # Or disable the firewall altogether.
- # networking.firewall.enable = false;
+ services.nginx = {
+ enable = true;
+ recommendedGzipSettings = true;
+ recommendedOptimisation = true;
+ recommendedProxySettings = true;
+ recommendedTlsSettings = true;
+ };
+
+ # TODO remove upon switching to production certs
+ services.oauth2_proxy.extraConfig = {
+ "ssl-insecure-skip-verify" = true;
+ "ssl-upstream-insecure-skip-verify" = true;
+ };
+
+ networking.firewall.allowedTCPPorts = [ 80 443 ];
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
- # on your system were taken. It‘s perfectly fine and recommended to leave
+ # on your system were taken. It's perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "23.11"; # Did you read the comment?
-
}