Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Language specific forums Russian (Русский) Веб сервер
  • Search

Редирект на другой домен nginx+php-fpm Topic is solved

Вопросы по работе Веб сервера
Apache + Nginx, Nginx + PHP5-FPM
Post Reply
  • Print view
Advanced search
3 posts • Page 1 of 1
justabot
Posts: 28
Joined: Thu May 25, 2017 10:35 pm

Редирект на другой домен nginx+php-fpm
  • Quote

Post by justabot » Tue Apr 02, 2019 6:25 pm

Подскажите пожалуйста самый простой способ, чтобы все домены на моем айпи перенаправлялись на другой внешний домен.
Top

grayfolk
Support team
Posts: 1111
Joined: Tue Jul 30, 2013 10:18 pm
Contact:
Contact grayfolk
Website Facebook Skype Twitter

Os: CentOS 6x
Web: nginx + php-fpm
Re: Редирект на другой домен nginx+php-fpm
  • Quote

Post by grayfolk » Tue Apr 02, 2019 7:48 pm

justabot wrote: ↑
Tue Apr 02, 2019 6:25 pm
Подскажите пожалуйста самый простой способ, чтобы все домены на моем айпи перенаправлялись на другой внешний домен.
В файле /etc/nginx/nginx.conf замените строку

Code: Select all

    include             /etc/nginx/conf.d/*.conf;
на:

Code: Select all

server {
        listen 443 ssl http2 default;
        listen 80 default;
        return 302 http://example.com;
}
Top

justabot
Posts: 28
Joined: Thu May 25, 2017 10:35 pm

Re: Редирект на другой домен nginx+php-fpm
  • Quote

Post by justabot » Tue Apr 02, 2019 8:03 pm

спасибо!
Top


Post Reply
  • Print view

3 posts • Page 1 of 1

Return to “Веб сервер”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password