From 8fb81bb6a7da16f8ca0124b448e5315aa5c8fba2 Mon Sep 17 00:00:00 2001 From: Maikel Linke Date: Tue, 16 Oct 2018 16:49:52 +1100 Subject: [PATCH] Configure Geocoder with API key as required by Google --- config/initializers/geocoder.rb | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 config/initializers/geocoder.rb diff --git a/config/initializers/geocoder.rb b/config/initializers/geocoder.rb new file mode 100644 index 0000000000..35b5510d5e --- /dev/null +++ b/config/initializers/geocoder.rb @@ -0,0 +1,6 @@ +# Google requires an API key with a billing account to use their API. +# The key is stored in config/application.yml. +Geocoder.configure( + use_https: true, + api_key: ENV.fetch('GOOGLE_MAPS_API_KEY', nil) +)