summaryrefslogtreecommitdiffstats
path: root/lass
diff options
context:
space:
mode:
Diffstat (limited to 'lass')
-rw-r--r--lass/2configs/radio.nix24
1 files changed, 24 insertions, 0 deletions
diff --git a/lass/2configs/radio.nix b/lass/2configs/radio.nix
index 60659d043..9da0a499c 100644
--- a/lass/2configs/radio.nix
+++ b/lass/2configs/radio.nix
@@ -146,6 +146,7 @@ in {
tables = {
filter.INPUT.rules = [
{ predicate = "-p tcp --dport 8000"; target = "ACCEPT"; }
+ { predicate = "-i retiolum -p tcp --dport 8001"; target = "ACCEPT"; }
];
};
};
@@ -259,6 +260,29 @@ in {
];
};
+ krebs.htgen.radio = {
+ port = 8001;
+ user = {
+ name = "radio";
+ };
+ script = ''
+ case "$Method $Request_URI" in
+ "POST /skip")
+ ${skip_track}/bin/skip_track
+ exit
+ ;;
+ "POST /good")
+ ${good_track}/bin/good_track
+ exit
+ ;;
+ "POST /current")
+ ${print_current}/bin/print_current
+ exit
+ ;;
+ esac
+ '';
+ };
+
services.nginx = {
enable = true;
virtualHosts."radio.lassul.us" = {