Search code examples
web-applicationsweinre

WEINRE : how to debug my app over the WAN (on a machine that is oustide my LAN)


I am using Weinre to debug my hybrid app. Is it possible to get the console logs from an app on machine that is outside of my LAN ? Maybe by putting my global IP in the script call instead of using my local IP :

<script src="http://GLO.BAL.IP:8080/target/target-script-min.js#anonymous"></script>

and by forwarding the 8080 port to my local IP my my router configuration...?

Thanks ps: by the way, if there is another solution than Weinre that can allow to do this, I will be glad to try it.


Solution

  • Answering myself :

    indeed, just forward the port 8080 to your local machine. When you call the weinre script, use your global ip:

    <script src="http://GLO.BAL.IP:8080/target/target-script-min.js#anonymous"></script>
    

    then go to your browser and open :

    http://GLO.BAL.IP:8080/client/#anonymous
    

    see here : http://gilesey.wordpress.com/tag/weinre/