Nginx answers

  • 0answers
    How to combine backends with nginx sstp vpn + https?
    There is nginx with stream configuration like this: stream { map $ssl_preread_server_name $name { vpn.example.com vpn; default https; } upstream https { server 127.0.0.1:443; } upstream vpn { server 192.168.23.4:443; } server { ...
    Nginx Landon Daniel, Jul 26, 2019

  • 0answers
    How can I redirect the request to the handler in case the file is not found?
    There is a need to serve files via a php script. Currently, if the file is not found, nginx returns 404 not found. How can I redirect request to php handler if file doesn't exist? Tried through try_files $ uri $ uri / /index.php?$query_string - but no effect. A piece of nginx 1.17 config: # ...
    Nginx Anonymous, Mar 15, 2019

  • 0answers
    How to save nginx settings when rebooting virtual machine?
    Good day / night. Added a new project to homestead.yaml. Accordingly, I rebooted the machine further - vagrant reload --provision. And now I look, and the nginx settings of the previous project have dropped to default. And I spent more than one day to set up a local domain. How not to lose ...
    Nginx Evangeline Bradford, Sep 16, 2020

  • 0answers
    How to set up nginx config correctly?
    Hello, I have dynamic domains and configured config for them. server { server_name *.example.com; listen 443 ssl; root /var/www/platforms/$host; index index.php index.html index.htm; location / { proxy_pass http://127.0.0.1:4000; proxy_set_header Host $host; ...
    Nginx Clare Hodges, Oct 9, 2019

  • 0answers
    Authentication between servers in nginx via auth, is it possible?
    there are two servers (frontend and backend), requests are proxied from frontend to backend. Is it possible to set up authentication for the backend using standard nginx tools, and automate the login and password input on the frontend so that any requests from the front to the back are proxied only ...
    Nginx Anonymous, Sep 9, 2020

  • 0answers
    After upgrading macOS to Big Sur, nginx doesn't work on port 80. Why?
    MacBook is working, upgraded from Catalina to Bis Sur. Installed local nginx server php-fpm mariadb, installed via brew. After updating the system, nginx refuses to work on port 80. The services are all running, but you can see that ngnix does not work on port 80, there are no logs at all. On other ...
    Nginx Olivia Krueger, Apr 25, 2019

  • 0answers
    Which tool should you choose?
    I have an Ubuntu machine with nginx servers. One of the servers does the following: -Serves pictures from disk for incoming http requests -For each request logs user data into a text file Further, this data is processed either manually or by bash scripts. Not very convenient. How the server ...
    Nginx Conner Reese, Aug 30, 2019

  • 0answers
    How do I add a slash at the end of a url?
    Hello. On a multilingual site, I try to add a slash at the end of the url on the main site to get mysite.com/en/ I use this directive but it doesn't work: location ~ "^/[a-z]{2}[\s]" { return 301 $1/;} Now url in this form mysite.com/en What could be the mistake?
    Nginx Isaac Hunt, May 19, 2020

  • 0answers
    How to implement data transfer to two different ports?
    I can’t figure out how to duplicate an incoming connection to two ports at once. Now with this configuration: conf stream { upstream backend { server IP:PORT_1; server IP:PORT_2; } server { listen 2000; proxy_pass backend; }}events { ...
    Nginx Anonymous, Aug 26, 2020

  • 0answers
    How to set a rule for a redirect in case of multilingualism?
    The site is multilingual, but because of this, there were problems with opening the sitemap (there are several of them). The map is successfully opened by url mysite.my/RU_en_sitemap_16-11-2020.xml but if there is a current language in url - 404, for example mysite.my/ru/RU_en_sitemap_16-11-2020 ...
    Nginx Anonymous, Dec 3, 2020

  • 0answers
    NGINX + LUA = Benchmark. Who has experience?
    The question is a little rhetorical ... There is such a stack: NGINX + LUA LUA uses a check for something by a key in Redis: if there is one, then we give static ... otherwise - 404 ... Everything is fine - everything works :) The question is: Before "screwing" the LUA check in NGINX ...
    Nginx Anonymous, Aug 6, 2019

  • 0answers
    How to redirect domain aliases via Nginx?
    The domain has multiple aliases. server_name site1.ru site2.ru site3.ru I need to redirect site1.ru/page for example to google.com And site2.ru/landing Redirect to Yandex.ru if ($http_host = 'site1.ru') { rewrite ^(.*) https:/google.com permanent; }if ($http_host = 'site2.ru') { ...
    Nginx Emma Ramos, Aug 6, 2019

  • 0answers
    What is the best way to provide fault tolerance for TomCat, Nginx and DB on Windows Server?
    Interested in the issue of ensuring fault tolerance of TomCat, Nginx and a database on a VPS server. I once used the NSSM utility that creates a service and monitors the process is it a good option or not? And what is the best way to organize a restart when one of the services stops? Or install ...
    Nginx Aden Murphy, May 25, 2019

  • 0answers
    Nginx. How to redirect request to php if file is missing?
    Hello. Can you please tell me how to make nginx requests so that requests for getting statics, in the absence of it, are redirected to a php script? My config: server { location / { location ~ [^/]\.ph(p\d*|tml)$ { try_files /does_not_exists @php; } ...
    Nginx Iris Ray, Mar 30, 2019

  • 0answers
    One domain and multiple applications in docker how to reverse nginx proxy?
    Help configure nginx There are several containerized applications running in docker on the same machine but on different ports. Each application individually runs on different ports. I want the following scheme of work domain.ru / app1 domain.ru/v1 - / app2 domain.ru/v3 - / app3 Config ...
    Nginx Anonymous, Nov 19, 2019

  • 0answers
    Why is nginx holding the map file?
    A directory contains the files bootstrap.min.css and bootstrap.min.css.map . Using javascript, these files are transferred from one directory to another, and the second is cleared beforehand. This happens on a virtual machine, in "shared folders". At the first start of the virtual machine, the ...
    Nginx Anonymous, Oct 3, 2019

  • 0answers
    Why am I getting ERR_EMPTY_RESPONSE?
    Hello. I am learning Docker and trying to deploy a project on it. I got the following configuration: Dockerfile: # Базовый образ с nginx и phpFROM richarvey/nginx-php-fpm# Добавляем наше веб приложениеADD app /var/www/app# Удаляем ...
    Nginx Hunter Hays, Oct 15, 2020

  • 0answers
    What's the best way to get static files on client servers?
    There are 2 VDS, 1 - with a background server, it stores all the statics, 2 - several client servers. And I want to store all the statics on server 1, and take this statics from the other servers 2 and give it to the client. What is the best way to implement this approach?
    Nginx Ava Rivers, May 20, 2020

  • 0answers
    How to properly deploy a nuxt application on a linux server?
    Available on Nuxt. It successfully opens on your local computer and all resources are shown. The application is deployed here: glinka.tk When I deployed to a linux server, the application is displayed, but the resources are not found, and an error appears: What did I do wrong when ...
    Nginx Alexandra Marshall, Sep 16, 2020

  • 0answers
    How to make nginx for a service on a different domain?
    There is a main site, let's call it https://example.com On it at the address / public-service / there is a service There is also another domain, let's call it https://public-service.com How can you make ALL requests to this additional domain proxied to the main domain with the ...
    Nginx Iris Hamilton, Feb 12, 2019