# legacy labsync, currently partly implemented in docker outside of this configuration { pkgs, ... }: { services.opentracker.enable = true; services.nginx.virtualHosts."labsync.lab.fablab-nea.de" = { locations = { "/" = { root = "/opt/docker/tftpgen/data"; extraConfig = '' autoindex on; ''; }; "/generator/".proxyPass = "http://127.0.0.1:8695/"; }; }; services.atftpd = { enable = true; root = pkgs.runCommand "pxelinux-tftproot" { } '' mkdir -p $out/pxelinux.cfg cp ${pkgs.syslinux}/share/syslinux/{ldlinux.c32,libcom32.c32,libutil.c32,lpxelinux.0,vesamenu.c32} $out cp ${./splash.png} $out/splash.png cp ${./pxelinux.cfg} $out/pxelinux.cfg/default # required to serve labsync/labsync.cfg, which is generated dynamically by a docker container ln -s /opt/docker/tftpgen/data $out/labsync ''; }; networking.firewall.allowedTCPPorts = [ 6881 # aria2 6969 # opentracker ]; networking.firewall.allowedUDPPorts = [ 6882 # aria2 69 # tftpd 6969 # opentracker ]; }