This commit is contained in:
zuckerberg 2021-05-16 11:09:10 -04:00
parent 01c2e19247
commit c0a2751249

View File

@ -11,29 +11,31 @@ in {
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
listen.address = "127.0.0.1"; services.icecast = {
admin.password = "hackme"; listen.address = "127.0.0.1";
extraConf = '' admin.password = "hackme";
<authentication> extraConf = ''
<source-password>hackme</source-password> <authentication>
</authentication> <source-password>hackme</source-password>
<http-headers> </authentication>
<header type="cors" name="Access-Control-Allow-Origin" /> <http-headers>
</http-headers> <header type="cors" name="Access-Control-Allow-Origin" />
<mount type="normal"> </http-headers>
<mount-name>/${cfg.mount}</mount-name> <mount type="normal">
<max-listeners>20</max-listeners> <mount-name>/${cfg.mount}</mount-name>
<burst-size>65536</burst-size> <max-listeners>20</max-listeners>
<hidden>false</hidden> <burst-size>65536</burst-size>
<public>false</public> <hidden>false</hidden>
</mount> <public>false</public>
''; </mount>
}; '';
services.nginx.virtualHosts.${cfg.hostname} = { };
enableACME = true; services.nginx.virtualHosts.${cfg.hostname} = {
forceSSL = true; enableACME = true;
locations."/${cfg.mount}" = { forceSSL = true;
proxyPass = "http://localhost:${toString cfg.listen.port}/${cfg.mount}"; locations."/${cfg.mount}" = {
proxyPass = "http://localhost:${toString cfg.listen.port}/${cfg.mount}";
};
}; };
}; };
} }