start new:
tmux
start new with session name:
tmux new -s myname
var http = require('http'); | |
var send = require('send'); | |
var urlParse = require('url').parse; | |
var count = 2; | |
var server = http.createServer(function (req, res) { | |
if (!--count) server.close(); // Only allow two connection and then exit. | |
send(req, urlParse(req.url).pathname) | |
.root(__dirname) | |
.pipe(res); |
\n | |
============= HOST: ==========\n | |
\n | |
local_ip: %{local_ip}\n | |
local_port: %{local_port}\n | |
remote_ip: %{remote_ip}\n | |
remote_port: %{remote_port}\n | |
\n | |
======= CONNECTION: ==========\n | |
\n |