X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/f0e429a924f06bc20e87190f012e72658f5818e7..c3d4f394005725d7069dda1947a5419eeb7b2e55:/cookbooks/nominatim/templates/default/nominatim.erb?ds=sidebyside diff --git a/cookbooks/nominatim/templates/default/nominatim.erb b/cookbooks/nominatim/templates/default/nominatim.erb index bf97f9a80..d36523d85 100644 --- a/cookbooks/nominatim/templates/default/nominatim.erb +++ b/cookbooks/nominatim/templates/default/nominatim.erb @@ -2,5 +2,8 @@ # DO NOT EDIT - This file is being maintained by Chef @define('CONST_Database_DSN', 'pgsql://@/<%= node[:nominatim][:database][:dbname] %>'); -@define('CONST_Website_BaseURL', '//nominatim.openstreetmap.org/'); +if (isset($_SERVER['HTTPS']) && !empty($_SERVER['HTTPS'])) + @define('CONST_Website_BaseURL', 'https://nominatim.openstreetmap.org/'); +else + @define('CONST_Website_BaseURL', 'http://nominatim.openstreetmap.org/');