2024-07-12 15:59:03 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
2024-08-05 15:23:08 -04:00
|
|
|
config = {
|
2024-03-17 13:16:45 -04:00
|
|
|
# geocoding service request timeout, in seconds (default 3):
|
2024-08-12 16:18:11 -04:00
|
|
|
timeout: 10,
|
2024-03-17 13:16:45 -04:00
|
|
|
|
|
|
|
|
# set default units to kilometers:
|
|
|
|
|
units: :km,
|
|
|
|
|
|
|
|
|
|
# caching (see Caching section below for details):
|
|
|
|
|
cache: Redis.new,
|
|
|
|
|
cache_options: {
|
2024-07-12 15:59:03 -04:00
|
|
|
expiration: 1.day # Defaults to `nil`
|
2024-03-17 13:16:45 -04:00
|
|
|
# prefix: "another_key:" # Defaults to `geocoder:`
|
2024-08-12 16:18:11 -04:00
|
|
|
},
|
2024-08-13 12:25:48 -04:00
|
|
|
always_raise: :all,
|
2024-08-05 15:23:08 -04:00
|
|
|
|
2024-08-13 12:25:48 -04:00
|
|
|
use_https: false,
|
|
|
|
|
lookup: :photon,
|
|
|
|
|
photon: { host: 'photon.chibi.rodeo' }
|
|
|
|
|
}
|
2024-08-05 15:23:08 -04:00
|
|
|
|
|
|
|
|
Geocoder.configure(config)
|