| { config, pkgs, ... }: | |
| { | |
| imports = [ <nixpkgs/nixos/modules/virtualisation/amazon-image.nix> ]; | |
| ec2.hvm = true; | |
| containers.df = import /root/armokweb/nix/container; | |
| networking.hostName = "armokweb"; | |
| time.timeZone = "UTC"; | |
| environment.systemPackages = with pkgs; [ | |
| wget vim curl git subversion htop zsh tmux psmisc | |
| ruby python27 | |
| ]; | |
| # Enable the OpenSSH daemon. | |
| services.openssh = { | |
| enable = true; | |
| passwordAuthentication = false; | |
| }; | |
| services.nginx = { | |
| enable = true; | |
| virtualHosts."armokweb.numin.it" = { | |
| http2 = true; | |
| forceSSL = true; | |
| enableACME = true; | |
| basicAuth = { | |
| "lobsters" = "armokweb"; | |
| }; | |
| locations."/" = { | |
| extraConfig = '' | |
| proxy_pass http://192.168.100.10:10000; | |
| proxy_set_header Upgrade $http_upgrade; | |
| proxy_set_header Connection $connection_upgrade; | |
| ''; | |
| }; | |
| }; | |
| appendHttpConfig = '' | |
| server { | |
| listen 80 default_server; | |
| server_name _; | |
| location / { | |
| empty_gif; | |
| } | |
| } | |
| ''; | |
| }; | |
| security.hideProcessInformation = true; | |
| networking.firewall.allowedTCPPorts = [ 22 80 443 ]; | |
| networking.firewall.enable = true; | |
| nixpkgs.config = { | |
| allowUnfree = true; | |
| }; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment