English 中文(简体)
Google maps api keys: dev -> staging -> production workflow
原标题:

Does anyone have a good solution for managing the maps api key, given that:

  • developers work locally, using localhost

  • we have a staging server, accessed internally via http://stagehost and externally (for customers) via IP address

  • finally, a production server (http://some.domain.com)

Two questions:

First, how do people manage their keys in this type of scenario, given that there s always a chance for a mixup. Internal servers are not accessible via stagehost.domain.com

Second, how can we address the staging server issue? The ip address is not accessible internally. Is this possible?

问题回答

I have a table in my database that stores the Google Map keys for all of my different URLs. Then I just pull out the correct key based on the URL. This lets the same code work for dev, test, & production across 100 sites.





相关问题
How to decide the current point reach on google map?

How to decide the current point reach on google map? I have a list of points (pickup points) of a route that I want to show in my google map with polyline. Now i have to get the current location of ...

Topographical or relief data in Map APIs

I was wondering if anyone knew of any map APIs that offer topographical or relief data? I ve had a quick look at Google and Bing APIs, but could find nothing there. Google allow you to view a map as ...

Using maps on Windows Mobile

I m experimenting with maps on different mobile platforms. Getting Google Maps to work on Android was easy, following this tutorial. Getting the same to work on Windows Mobile is a different matter. ...

Adding a custom icon to a google map

I need a hand adding a custom icon to some Google Maps javascript. Code below for your reference: function populateMap() { var map = new GMap2(document.getElementById("map")); map.setCenter(new ...

RSS to KML Overlay

I m want to display my blog as a Google Map overlay (each post contains geotags). How can I dynamically create a KML overlay from an RSS? Or better, how can I create a loop (PHP) that would display ...

开放街道地图管理员

我需要开放Street的标记管理员。 地图,如山角地图。

热门标签