A daemon for keeping the system timezone up-to-date based on the current location.
Unfortunately, GeoClue is stubbornly a Gnome and desktop-centric service. There's no way (literally) to use it from a system service without manual intervention, unless you can convince them to add your app to a whitelist. You can:
- Configure a geoclue agent (e.g., the demo agent), and configure the demo agent to allow
localtimed. I've tried having localtime autostart this if it can't find an agent running, but GeoClue insisted that there was no agent running anyways. - Disable geoclue agents by clearing the agent whitelist in
/etc/geoclue/geoclue.conf. This is by far the simplest approach, but it will allow arbitrary apps to get your location.
If possible, use your package manager:
Otherwise, follow the instructions below.
$ make
$ sudo make install
$ sudo systemctl enable --now localtime.service
- geoclue2
- systemd >= 235 (for full dynamic user support)
- dbus
- polkit (to run as a non-root user)
- go
- make
- m4