new work flow 1
This commit is contained in:
9
random_port.py
Executable file
9
random_port.py
Executable file
@ -0,0 +1,9 @@
|
||||
#!/usr/bin/env python3
|
||||
import socket
|
||||
|
||||
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
|
||||
s.bind(('', 0))
|
||||
addr = s.getsockname()
|
||||
print (addr[1])
|
||||
s.close()
|
||||
exit(0)
|
Reference in New Issue
Block a user