Yes Ben !
here is my nginx configuration file :
server {
  listen 0.0.0.0:86;
  server_name bongda.com.vn;
  access_log /var/log/nginx/yourdomain.log;
........
  location / {
        # The IP(s) on which your node server is running , I chose the
port 3000
        proxy_pass      http://127.0.0.1:3001;
        proxy_set_header X-Real-IP      $remote_addr;
        proxy_set_header X-Forwarded-For   $proxy_add_x_forwarded_for;
        proxy_set_header Host           $http_host;
        proxy_set_header X-NginX-Proxy  true;
        proxy_redirect off;
  }

...
and about node.js file :
var http = require('http');

http.createServer(function(req, res){
        res.writeHead(200, {'Conten-type': 'text/plain'});
        res.end(' ');
}).listen(3001, "127.0.0.1");


On 29 Tháng Năm, 21:29, Ben Noordhuis <[email protected]> wrote:
> On Tue, May 29, 2012 at 4:24 PM, thuan le minh <[email protected]> 
> wrote:
>
>
>
>
>
>
>
>
>
> > Hi all,
>
> > i installed Nginx and Node.js in my server !
> > i tested Nginx , it worked Ok
>
> > when i try ran my node.js file , i got an error :
>
> > node.js:201
> >        throw e; // process.nextTick error, or 'error' event on first
> > tick
> >              ^
> > Error: listen EADDRNOTAVAIL
> >    at errnoException (net.js:614:11)
> >    at Array.0 (net.js:689:28)
> >    at EventEmitter._tickCallback (node.js:192:40)
>
> > some body help me fix it ?
>
> > thank !
>
> You should post your code but, at a glance, it seems you're trying to
> bind to an IP address you don't actually own.

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to