fixup postgres and hedgedoc
This commit is contained in:
parent
6a23fdc3f2
commit
af01cffa4d
10 changed files with 52 additions and 43 deletions
|
|
@ -4,7 +4,7 @@ let
|
|||
cfg = config.services.hedgedoc.settings;
|
||||
in
|
||||
{
|
||||
nginx.virtualHosts."${config.networking.fqdn}" = {
|
||||
services.nginx.virtualHosts."md.${config.networking.domain}" = {
|
||||
default = true;
|
||||
quic = true;
|
||||
kTLS = true;
|
||||
|
|
@ -14,6 +14,9 @@ in
|
|||
"/" = {
|
||||
proxyPass = "http://${cfg.host}:${toString cfg.port}";
|
||||
recommendedProxySettings = true;
|
||||
extraConfig = ''
|
||||
#add_header Content-Security-Policy "frame-src 'self'; default-src 'self'; script-src 'self'; img-src 'self'; style-src 'self' 'unsafe-inline'; font-src 'self'; form-action 'self'; upgrade-insecure-requests;" always;
|
||||
'';
|
||||
};
|
||||
"/socket.io/" = {
|
||||
proxyPass = "http://${cfg.host}:${toString cfg.port}";
|
||||
|
|
@ -23,16 +26,20 @@ in
|
|||
"/metrics" = {
|
||||
proxyPass = "http://${cfg.host}:${toString cfg.port}";
|
||||
recommendedProxySettings = true;
|
||||
#allow 195.160.173.255;
|
||||
#allow 2001:678:760:cccb::ffff;
|
||||
#deny all;
|
||||
extraConfig = ''
|
||||
allow 195.160.173.14;
|
||||
allow 2001:678:760:cccb::14;
|
||||
deny all;
|
||||
'';
|
||||
};
|
||||
"/status" = {
|
||||
proxyPass = "http://${cfg.host}:${toString cfg.port}";
|
||||
recommendedProxySettings = true;
|
||||
#allow 195.160.173.255;
|
||||
#allow 2001:678:760:cccb::ffff;
|
||||
#deny all;
|
||||
extraConfig = ''
|
||||
allow 195.160.173.14;
|
||||
allow 2001:678:760:cccb::14;
|
||||
deny all;
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue