mirror of
https://github.com/NginxProxyManager/nginx-proxy-manager.git
synced 2026-04-25 17:35:52 +03:00
[GH-ISSUE #927] convert docker name to variable #784
Labels
No labels
awaiting feedback
bug
cannot reproduce
dns provider request
duplicate
enhancement
enhancement
enhancement
good first issue
help wanted
invalid
need more info
no certbot plugin available
product-support
pull-request
question
stale
troll
upstream issue
v2
v2
v2
v3
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/nginx-proxy-manager-NginxProxyManager#784
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @GurjinderSingh on GitHub (Mar 5, 2021).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/927
Is your feature request related to a problem? Please describe.
current natural version when create new custom location.
try to change in custom location to variable and add extra rule set
output
Problem : if we set variable below proxy pass will not work. please let me know if I made mistake
working best configuration location block
for ubuntu vnc need to add websocket config : https://github.com/jc21/nginx-proxy-manager/issues/926
Describe the solution you'd like
Allow option to make host variable or do it by default. I believe most of NPM user use it with docker hosts so any docker container can crash or admin can delete will crash NPM.
Why did I go crazy for it 0_0 ??
I am trying to setup NPM with three DO VPS docker swarm.
problem arose when my one vps with NPM and other container crashed while testing. NPM started on another server as expected but nginx kept crashing due to one container failed to start.
Describe alternatives you've considered
I have to create every custom location like this. not tested but maybe I have to create main hosts too
Additional context
https://github.com/jc21/nginx-proxy-manager/issues/926
@GurjinderSingh commented on GitHub (Mar 14, 2021):
found a way around for my dynamic container problem. when testing with multiple service add custom host on some services failed to work properly. plus for some container I love to use for testing and kill them when not needed EX, ubuntu vnc, firefox phpmyadmin, theia-php and some others.
Target : dynamic containers aka only boot up container when required served by NPM.
Problem : NPM nginx restart will never boot until all proxy host/container available
solution add each host dynamically with $var to proxy host. scroll up ^-^
solution for devolvement use dynamic subdomain with regex provide container name and port in subdomain
HowTO
step 1
step 2
Step 3
File to add : nginx/custom/http.conf
read more https://github.com/jc21/nginx-proxy-manager/pull/948 -
github.com/jc21/nginx-proxy-manager@b7b808d98d/docker/rootfs/etc/nginx/nginx.conf (L73)