# 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, ... }: { boot.loader.grub.enable = true; boot.loader.grub.version = 2; boot.loader.grub.device = "/dev/sda"; # or "nodev" for efi only networking.hostName = "spoutnik"; services.openssh.ports = [ 220 ]; deuxfleurs.network_interface = "enp0s25"; deuxfleurs.lan_ip = "192.168.0.40"; deuxfleurs.ipv6 = "::"; #TODO deuxfleurs.cluster_ip = "10.14.0.0"; deuxfleurs.is_raft_server = false; #TODO # Nginx configuration: services.nginx = { enable = true; # Use recommended settings recommendedGzipSettings = true; recommendedOptimisation = true; recommendedProxySettings = true; recommendedTlsSettings = true; # Add any further config to match your needs, e.g.: virtualHosts = let base = locations: { inherit locations; forceSSL = true; enableACME = true; }; proxy = addr: port: base { "/".proxyPass = "http://" + addr + ":" + toString(port); }; in { "axl.deuxfleurs.fr" = proxy "192.168.0.60" 80; "warez.luxeylab.net" = proxy "192.168.0.50" 80; }; }; # ACME: security.acme = { acceptTerms = true; email = "adrien@luxeylab.net"; }; }