NginxProxyManager / NginxProxyManager/nginx-proxy-manager

Issue with Mastodon installed via source

Open
#4,585 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug stale
Dominant language
TypeScript
Stars
34.2k
Forks
3.9k
Avg merge
21h 12m
Merged PRs (30d)
20

Description

Checklist

  • Have you pulled and found the error with jc21/nginx-proxy-manager:latest docker image?
    • Yes
  • Are you sure you're not using someone else's docker image?
    • Yes
  • Have you searched for similar issues (both open and closed)?
    • Yes

Describe the bug

I installed Mastodon from source and configured it to be on port 3000. I have gotten it to at least partially work, however under advanced I'm unable to add these lines:

proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";

when I do, NPM removes the existing conf file, and replaces it with nothing.

Nginx Proxy Manager Version

v2.12.3 © 2024

To Reproduce
Steps to reproduce the behavior:

  1. Add New Proxy Host
  2. Turn on Websockets Support
  3. Add SSL
  4. Add a Custom Location (e.g., for /api/v1/streaming, pointing to your streaming server details).
  5. Go to the Advanced tab of this specific Custom Location (e.g., for /api/v1/streaming).
    Add the lines:

proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";

  1. Click 'Save' for the Proxy Host.
    Expected behavior

It should work like it does in the default nginx

Screenshots

Image

Image

[6/17/2025] [4:22:27 AM] [Nginx ] › ⬤ debug Deleting file: /data/nginx/proxy_host/4.conf
[6/17/2025] [4:22:27 AM] [Nginx ] › ⬤ debug Could not delete file: {
"errno": -2,
"code": "ENOENT",
"syscall": "unlink",
"path": "/data/nginx/proxy_host/4.conf"
}
[6/17/2025] [4:22:27 AM] [Nginx ] › ℹ info Reloading Nginx
[6/17/2025] [4:22:27 AM] [Global ] › ⬤ debug CMD: /usr/sbin/nginx -s reload

Operating System

Ubuntu 22.04.5 LTS
Docker version 28.2.2, build e6534b4
Mastodon v4.3.8

Additional context

Did also find that this error presented by erasing and then not replacing the conf file in nginx-proxy-manager/data/nginx/proxy_host till the lines were removed.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the proxy-host and custom-location steps with Mastodon on port 3000, then inspect the generated /data/nginx/proxy_host/4.conf and the deletion/reload logs. Trace how the Advanced-tab directives are processed and persisted; done means the directives remain in the generated configuration and Nginx reloads successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, nginx
Domain
devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.