port can be specified on the commandline.
This commit is contained in:
parent
d698dca2ab
commit
fbe90e14e3
1 changed files with 6 additions and 2 deletions
|
|
@ -82,7 +82,11 @@ public class PixelServer extends ChannelHandlerAdapter {
|
||||||
|
|
||||||
public static void main(final String[] args) throws InterruptedException,
|
public static void main(final String[] args) throws InterruptedException,
|
||||||
IOException {
|
IOException {
|
||||||
new PixelServer(8080).run();
|
int port = 8080;
|
||||||
|
if(args.length == 1) {
|
||||||
|
port = Integer.parseInt(args[0]);
|
||||||
|
}
|
||||||
|
System.out.println("Starting server on port " + port);
|
||||||
|
new PixelServer(port).run();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue