[GH-ISSUE #2264] How can I use this nginx configuration with npm? #1613

Closed
opened 2026-02-26 07:31:46 +03:00 by kerem · 2 comments
Owner

Originally created by @kpatdev on GitHub (Sep 15, 2022).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/2264

I am trying to setup a reverse proxy for Spleeter-Web with NPM. The reverse proxy is working great. I can reach the site through my subdomain and process files. I just can't seem to get my requests to be proxied correctly (downloading files from the webpage). Here's the nginx configuration that they want to use:

    server <container IP>:8000;
}

server {
    listen 80;
    client_max_body_size 50M;

    location /static/ {
        alias /webapp/staticfiles/;
    }

    location /media/ {
        alias /webapp/media/;
    }

    location / {
        proxy_pass http://django_react;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
        proxy_set_header Host $host;
        proxy_set_header Authorization "";
        proxy_redirect off;
    }
}

Every time I try to download a processed file or playback any media on the webpage I get a 404. I can verify the files are being created and the container has access to them. It is a matter of getting the right config in npm and I just haven't been able to figure it out. Here's what I have tried so far and have not had any success.

image
image

I just can't seem to figure out what else I should do. The reverse proxy should be taking me to my files at spleeter.domain.com/media* however, it just returns a 404 even though the files are present. Which part of the config am I messing up?

Appreciate the help!

Originally created by @kpatdev on GitHub (Sep 15, 2022). Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/2264 I am trying to setup a reverse proxy for Spleeter-Web with NPM. The reverse proxy is working great. I can reach the site through my subdomain and process files. I just can't seem to get my requests to be proxied correctly (downloading files from the webpage). Here's the nginx configuration that they want to use: ```upstream django_react { server <container IP>:8000; } server { listen 80; client_max_body_size 50M; location /static/ { alias /webapp/staticfiles/; } location /media/ { alias /webapp/media/; } location / { proxy_pass http://django_react; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header Host $host; proxy_set_header Authorization ""; proxy_redirect off; } } ``` Every time I try to download a processed file or playback any media on the webpage I get a 404. I can verify the files are being created and the container has access to them. It is a matter of getting the right config in npm and I just haven't been able to figure it out. Here's what I have tried so far and have not had any success. ![image](https://user-images.githubusercontent.com/54118820/190310364-d7c624a4-01f0-4f98-bafc-0f8fa5b7d05f.png) ![image](https://user-images.githubusercontent.com/54118820/190311346-4da006dc-9a1e-4c2a-9091-e91b43ecc976.png) I just can't seem to figure out what else I should do. The reverse proxy should be taking me to my files at `spleeter.domain.com/media*` however, it just returns a 404 even though the files are present. Which part of the config am I messing up? Appreciate the help!
kerem closed this issue 2026-02-26 07:31:46 +03:00
Author
Owner

@keniobats commented on GitHub (Sep 30, 2022):

Hi @dezerving, any updates about this? I'm facing the same issue with Django. Thanks!

<!-- gh-comment-id:1263576853 --> @keniobats commented on GitHub (Sep 30, 2022): Hi @dezerving, any updates about this? I'm facing the same issue with Django. Thanks!
Author
Owner

@kpatdev commented on GitHub (Oct 6, 2022):

Unraid Support? JeffreyCA/spleeter-web#57

Take a look here https://github.com/JeffreyCA/spleeter-web/issues/57 I was able to get things solved today because I had a folder mapping issue with NPM.

NPM needs access to the directories so make sure they are correctly mapped for NPM as well as the app.

<!-- gh-comment-id:1270360978 --> @kpatdev commented on GitHub (Oct 6, 2022): > Unraid Support? JeffreyCA/spleeter-web#57 Take a look here https://github.com/JeffreyCA/spleeter-web/issues/57 I was able to get things solved today because I had a folder mapping issue with NPM. NPM needs access to the directories so make sure they are correctly mapped for NPM as well as the app.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/nginx-proxy-manager-NginxProxyManager#1613
No description provided.