allow access to files without auth
This commit is contained in:
@@ -54,7 +54,7 @@ in {
|
|||||||
quic = cfg.https;
|
quic = cfg.https;
|
||||||
http3 = cfg.https;
|
http3 = cfg.https;
|
||||||
locations = {
|
locations = {
|
||||||
"~* \\.(jpg|png)$".extraConfig = ''
|
"~* ^/assets/.*\\.(jpg|png)$".extraConfig = ''
|
||||||
add_header Access-Control-Allow-Origin *;
|
add_header Access-Control-Allow-Origin *;
|
||||||
'';
|
'';
|
||||||
"/stash" = {
|
"/stash" = {
|
||||||
@@ -70,6 +70,17 @@ in {
|
|||||||
proxy_pass http://localhost:7777;
|
proxy_pass http://localhost:7777;
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
"/stash/files" = {
|
||||||
|
extraConfig = ''
|
||||||
|
proxy_redirect off;
|
||||||
|
proxy_set_header Host $host;
|
||||||
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
|
proxy_set_header X-NginX-Proxy true;
|
||||||
|
proxy_pass http://localhost:7777;
|
||||||
|
'';
|
||||||
|
};
|
||||||
"/tracker-site" = {
|
"/tracker-site" = {
|
||||||
tryFiles = "$uri $uri/ /tracker-site/index.html =404";
|
tryFiles = "$uri $uri/ /tracker-site/index.html =404";
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ buildGoModule rec {
|
|||||||
src = fetchGit {
|
src = fetchGit {
|
||||||
url = "git@github.com:kropatz/kop-fileshare.git";
|
url = "git@github.com:kropatz/kop-fileshare.git";
|
||||||
ref = "master";
|
ref = "master";
|
||||||
rev = "73456c32d3d070d457f95973403ca94bdddea95d";
|
rev = "ac2c4114c65b21f840fa807e44edf54fffe2d4c7";
|
||||||
};
|
};
|
||||||
vendorHash = "sha256-OQ6rNgOQHrrhE7DT+ulwpWJCDJ4DeJiDzriAu3mfS7I=";
|
vendorHash = "sha256-OQ6rNgOQHrrhE7DT+ulwpWJCDJ4DeJiDzriAu3mfS7I=";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user