suggestion:  Not sure if you like this style, but many chrome api's do a type of internal function overloading based on argument type.  Thus, opt_host could come first in this argument list here.  Then check if its type is Number, to know if you should use its value as the port or not.

This users can .listen(80) or .listen('1.2.3.4', 80) which I think is cleaner looking.