Mongoose http server ip address

If you are asking a question, please follow this template:

  1. My goal is: http server running.

  2. My actions are: a server to setup initial connection

  3. The result I see is: i ran both http server and client and they both communicate, however on localhost. I looked into code and i see that mg_bind option is only port. how do i change it to
    [A]. ipaddress say 192.168.0.10 with port 8000.
    [B]. i could not find any example or could understand how to use the API’s to pass ipaddress.

  4. My expectation & question is: [describe your expectation and your question]
    a third party device will connect to my http server and in this regard i wanted to have ipaddress bind rather than localhost bind.

Thanks

mg_bind(&mgr, "192.168.0.10:8000", ev_handler);
mg_bind

1 Like