Use listen and port variables

Change-Id: I8e1b3254abdaa8a28b09587c643421abf3ed7ae2