I found xip.io which automatically converts a fixed url to a embedded localhost domain.
For example lets say your localhost server is running on 127.0.0.1:8000
You can go to http://www.127.0.0.1.xip.io:5555/
to access this server.
You can then add this address to Oauth configuration for Facebook or Google.