Problem with proxy

boo

Well-known member
Registered
Joined
Aug 29, 2019
Messages
54
Points
28

Reputation:

/etc/nginx/sites-available/default

In there you will see proxy_pass something like this :

proxy_pass https://127.0.0.1:444;

You need to add below:

proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;

And restart nginx: sudo systemctl restart nginx
 

outplayed

Moderator
Moderator
Collaborate
Registered
Joined
Oct 27, 2019
Messages
151
Points
63

Reputation:

Inside the nginx directory doesnt exist such ubication, it does inside the apache2 location /etc/apache2/sites-available/default

But the default script is empty
 

outplayed

Moderator
Moderator
Collaborate
Registered
Joined
Oct 27, 2019
Messages
151
Points
63

Reputation:

This the nginx directory
nginx.PNG


This apache2
apache.PNG
 

sucre13

Moderator
Staff member
Moderator
Collaborate
Registered
Joined
Jan 19, 2019
Messages
836
Points
153

Reputation:

my question is and what is the problem with that proxy the vps is attacking you ?????? '' only that proxy is in your vps
 

sucre13

Moderator
Staff member
Moderator
Collaborate
Registered
Joined
Jan 19, 2019
Messages
836
Points
153

Reputation:

if you continue with the same problem use the cento 7 operating system with the cento web panel
 

outplayed

Moderator
Moderator
Collaborate
Registered
Joined
Oct 27, 2019
Messages
151
Points
63

Reputation:

i have a ton of webs in that vps i dont think im gonna change all that again, must be another way
 

dinhphucv

VIP Member
V.I.P Member
Registered
Joined
Sep 16, 2019
Messages
7
Points
13

Reputation:

Add to your config.php
Code:
$_SERVER['REMOTE_ADDR'] = $_SERVER["HTTP_X_FORWARDED_FOR"];
 

outplayed

Moderator
Moderator
Collaborate
Registered
Joined
Oct 27, 2019
Messages
151
Points
63

Reputation:

THX to all who helped me into this mess, i already did it, im doing a tutorial and ill post it in case anyone need it in a future.
 

thomsa

Moderator
Staff member
Moderator
S.V.I.P Member
Collaborate
Registered
Joined
Jun 22, 2019
Messages
1,066
Points
173

Reputation:

in this case i think vesta install not complete.

or bug on reverse proxy and apache.
 

thomsa

Moderator
Staff member
Moderator
S.V.I.P Member
Collaborate
Registered
Joined
Jun 22, 2019
Messages
1,066
Points
173

Reputation:

yes, it is.
i use directadmin nginx_apache not problem.

to backup xenforo+db and install new os&vesta.
 

thomsa

Moderator
Staff member
Moderator
S.V.I.P Member
Collaborate
Registered
Joined
Jun 22, 2019
Messages
1,066
Points
173

Reputation:

on cloudflare you set to Flexible SSL ?
 

thomsa

Moderator
Staff member
Moderator
S.V.I.P Member
Collaborate
Registered
Joined
Jun 22, 2019
Messages
1,066
Points
173

Reputation:

on vesta domain cp you set nginx caching or http2 or not ?

2020-03-20_15-18-20.jpeg
 
Top