searching example config for my setup
Jelle de Jong
jelledejong at powercraft.nl
Thu May 19 16:29:41 MSD 2011
On 18-05-11 23:28, Jelle de Jong wrote:
> On 18-05-11 22:28, Jelle de Jong wrote:
>> I am searching for an example configuration file for nginx for the
>> follow set-up:
> Looking at several snippet I made the above config, it seems to partaly
> do what I want... Is this the correct way (efficient/secure)?
server {
listen 80;
server_name a.powercraft.nl;
access_log /var/log/nginx/a.powercraft.nl.access.log;
location / {
proxy_set_header Host $host;
proxy_pass http://192.168.24.63/;
}
}
server {
listen 80;
server_name b.powercraft.nl;
access_log /var/log/nginx/c.powercraft.nl.access.log;
location / {
proxy_set_header Host $host;
proxy_pass http://192.168.24.63/;
}
}
server {
listen 80;
listen 443;
server_name c.powercraft.nl;
access_log /var/log/nginx/c.powercraft.nl.access.log;
location / {
proxy_set_header Host $host;
proxy_pass http://192.168.24.64/;
}
}
I did some more research and found:
http://wiki.nginx.org/HttpProxyModule
http://wiki.nginx.org/VirtualHostExample
I came up with the above set-up that partly fills my need :)
Is it possbible to for http://192.168.24.63/ to see the IP-address of
the original browser requesting the http data? Now only the IP of the
nginx system is logged? (I know this is because of the proxy so I am
wondering if this is something that can be fixed?)
Is the configuration correct? Can it be improved? Hints & tips?
Kind regards,
Jelle de Jong
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 316 bytes
Desc: OpenPGP digital signature
URL: <http://nginx.org/pipermail/nginx/attachments/20110519/b1babf37/attachment.pgp>
More information about the nginx
mailing list