This repository has no description
0

Configure Feed

Select the types of activity you want to include in your feed.

services radio: move proxy config to proxy.nix

+11 -28
+1 -27
machines/prism/config.nix
··· 82 82 openssh.authorizedKeys.keys = [ "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDQFaYOWRUvHP6I37q9Dd4PJOq8FNQqAeJZ8pLx0G62uC450kbPGcG80rHHvXmk7HqQP6biJmMg48bOsvXAScPot2Qhp1Qc35CuUqVhLiTvUAsi8l/iJjhjZ23yRGDCAmW5+JIOzIvECkcbMnG7YoYAQ9trNGHe9qwGzQGhpt3QVClE23WtE3PVKRLQx1VbiabSnAm6tXVd2zpUoSdpWt8Gpi2taM4XXJ5+l744MNxFHvDapN5xqpYzwrA34Ii13jNLWcGbtgxESpR+VjnamdWByrkBsW4X5/xn2K1I1FrujaM/DBHV1QMaDKst9V8+uL5X7aYNt0OUBu2eyZdg6aujY2BYovB9uRyR1JIuSbA/a54MM96yN9WirMUufJF/YZrV0L631t9EW8ORyWUo1GRzMuBHVHQlfApj7NCU/jEddUuTqKgwyRgTmMFMUI4M0tRULAB/7pBE1Vbcx9tg6RsKIk8VkskfbBJW9Y6Sx6YoFlxPdgMNIrBefqEjIV62piP7YLMlvfIDCJ7TNd9dLN86XGggZ/nD5zt6SL1o61vVnw9If8pHosppxADPJsJvcdN6fOe16/tFAeE0JRo0jTcyFVTBGfhpey+rFfuW8wtUyuO5WPUxkOn7xMHGMWHJAtWX2vwVIDtLxvqn48B4SmEOpPD6ii+vcpwqAex3ycqBUQ==" ]; 83 83 }; 84 84 } 85 - { 86 - services.nginx.virtualHosts."radio.lassul.us" = { 87 - enableACME = true; 88 - addSSL = true; 89 - locations."/" = { 90 - # recommendedProxySettings = true; 91 - proxyWebsockets = true; 92 - proxyPass = "http://radio.r"; 93 - extraConfig = '' 94 - proxy_set_header Host radio.r; 95 - # get source ip for weather reports 96 - proxy_set_header user-agent "$http_user_agent; client-ip=$remote_addr"; 97 - ''; 98 - }; 99 - }; 100 - krebs.htgen.radio-redirect = { 101 - port = 8000; 102 - scriptFile = pkgs.writers.writeDash "redir" '' 103 - printf 'HTTP/1.1 301 Moved Permanently\r\n' 104 - printf "Location: http://radio.lassul.us''${Request_URI}\r\n" 105 - printf '\r\n' 106 - ''; 107 - }; 108 - krebs.iptables.tables.filter.INPUT.rules = [ 109 - { predicate = "-p tcp --dport 8000"; target = "ACCEPT"; } 110 - ]; 111 - } 85 + ../../2configs/services/radio/proxy.nix 112 86 ../../2configs/exim-smarthost.nix 113 87 ../../2configs/privoxy-retiolum.nix 114 88 ../../2configs/binary-cache/server.nix
+10 -1
2configs/services/radio/proxy.nix
··· 1 - { config, pkgs, ... }: 1 + { pkgs, ... }: 2 2 { 3 3 services.nginx.virtualHosts."radio.lassul.us" = { 4 4 enableACME = true; ··· 14 14 ''; 15 15 }; 16 16 }; 17 + krebs.htgen.radio-redirect = { 18 + port = 8000; 19 + scriptFile = pkgs.writers.writeDash "redir" '' 20 + printf 'HTTP/1.1 301 Moved Permanently\r\n' 21 + printf "Location: http://radio.lassul.us''${Request_URI}\r\n" 22 + printf '\r\n' 23 + ''; 24 + }; 25 + networking.firewall.allowedTCPPorts = [ 8000 ]; 17 26 }