I gonna to make a simple WebSocket application waiting the clients to connect to. The clients would be Android users, and the application itself is a simple chat for two peoples. So for the Android application I need to know WebSocket address (starts with ws:// or wss://). I already have some website, where I install nodejs. But after couple of days I completely stuck what's going on and how make something work. I would be even glad to see nodejs catches any WebSocket messages and that's it.
I read some manuals about nodejs and socket.io, and again I have no idea where to get that ws:// address and make it work somehow.
For example, from socket.io chat manual, we have:
var app = require('express')();
var http = require('http').Server(app);
var io = require('socket.io')(http);
app.get('/', function(req, res){
res.sendfile('index.html');
});
io.on('connection', function(socket){
console.log('a user connected');
});
http.listen(3000, function(){
console.log('listening on *:3000');
});
Is that already simple websocket application? Where is my desired ws:// address in that case? Maybe should I just upload that bunch of code on my server and send queries to ws://mydomain.com:3000 ?