OpenWrt Forum Archive

Topic: Automatically update timezone by geolocation

The content of this topic has been archived on 28 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hello,

Looking for a script that could automatically setup the right timezone on the first boot of my router.

I manage to update it remotly but it needs to be configured from an external webpage and I would to have this done automatically on boot.

Any suggestion about a light script to do that ?

Thank you,
Nans

Nans,

from your question it's not quite clear (at least to me) wherever you're asking for help getting timezone by ip or for help integrating existing timezone from ip script into OpenWrt router.

I can't help you with the former (google geoip linux/bash tho) as far as getting things done on boot, easiest way would be calling your script from /etc/rc.local, you can also write a service or a hotplug script.

I hope this helps.

Why not hardcode it? Is your router running circles around the planet?

The discussion might have continued from here.