Geoclue
Appearance
Geoclue is a D-Bus geoinformation service. Geoclue can give you a location based on device GPS, a GPS of a device on your network, 3G modems, GeoIP, or WiFi.
Many of these may require additional setup, such as WiFi which once relied on Mozilla Location Service, but that service is now retired. Alternatives such as beaconDB may be used as a drop in replacement. Option may be found under services.geoclue2.
Configuration:
Example:
❄︎ /etc/nixos/configuration.nix
# Set Geoclue as the default location provider
location.provider = "geoclue2";
# Enable Geoclue
services.geoclue2 = {
enable = true;
# if using beaconDB
# geoProviderUrl = "https://api.beacondb.net/v1/geolocate";
};