To check if you have required tools run the following commands on your terminal:
git clone https://github.com/Markojudas/java-chatserver.git
cd java-chatserver/src
javac ChatServer.java
java ChatServer
On a different terminal you can use telnet to connect to the server as it is listening for connections:
telnet localhost 8888
Note: I'd recommend running this application on a virtual machine or in a cloud instance (AWS/GCP/Linode) with a public IP, as long as you open port 8888
.
If so, run you can connect using your public IP
instead of localhost
.
telnet <public-ip> 8888
Here is a little example - Yes, I am playing the role of all 3 users