Allow port number to be specified on command line

@wedaly