Hi Federico Need your help again !
I have registered device by calling http://172.18.0.x:8000/controller/register/ with information as secret , name , backend , mac_address . device registred successfully with below response registration-result: success uuid: de029013b6e848b29b52c17ccb7c6dca key: 8hrvy4fFYzvwTN0IRhvVl6bGQCQTHRhB hostname: openwrt2 is-new: 1 But last IP is getting updated wrong. it is updating gateway ip always not device ip. for example if device ip is 172.18.0.3 or 172.18.0.4 , it always take 172.18.0.1 as last ip . My openwisp is running on docker window and ip persisitent route is added and I am able to access openwisp via http://172.18.0.2:8000 Could you please help here . On Friday, July 12, 2019 at 12:34:55 PM UTC+5:30, Amit Goyal wrote: > > Thanks a lot Federico for your help! I will start implementation as per > your suggestion now . > > Regards > Amit > > On Thursday, July 11, 2019 at 6:22:11 PM UTC+5:30, Federico Capoano wrote: >> >> On Thu, Jul 11, 2019 at 3:48 AM Amit Goyal <[email protected]> wrote: >> >>> Hi Federico >>> >>> Thanks for providing so details answer. Sure it will help me . >>> >>> One more query -: *Can we register device only with MAC address >>> information* ? If we do device registration using HTTP resource , >>> minimum information required is UUID and KEY or Shared_Secret . >>> >>> Client does want to share shared_secret due to security reason and UUID >>> & Key is generated by Openwisp itself . Is there way we can generate UUID >>> & Key using Device Mac Address ? >>> >> >> Not at the moment, but regarding the key, when using "consistent key >> generation >> <https://github.com/openwisp/openwisp-config#consistent-key-generation>", >> which is enabled by default, the key is generated consistently according to >> the mac address and the shared secret. >> It means that the key is always the same for the same device. So if the >> device flash is reset and it registers again it will use the same DB object. >> >> If you want to generate your own UUID and keys, instead of using the HTTP >> resource you have to use the Django ORM to create Device and Config objects >> manually, depends on your experience with django, for someone who has some >> experience with Django and the django ORM, doing this is almost trivial, >> you just need to understand how the base models of openwisp-controller work. >> >> Best regards >> Federico >> > -- You received this message because you are subscribed to the Google Groups "OpenWISP" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web, visit https://groups.google.com/d/msgid/openwisp/cc293f44-ea34-433c-af3e-9131f135c07f%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
