You need to port forward, after that it already runs on your public ip, the server is automatically on port 25565 but you can change that in server.properties