about gitmap

gitmap is a simple, small, 100% free/open-source, collaborative map editor that runs mostly in a web browser. It integrates community FOSS projects and data sources.

run gitmap

FAQ

Why?

Because it's fun to browse around a map, and nice to know place markers like in a wiki, and nice to find neighbours. This particular installation is for locating Red Hat remotees / offices. Other installations may store whatever they like.

Who?

fche (gitmap integration scripts), Open Streetmap (background map), Leaflet (map rendering javascript library + plugins), and others.

How to use it?

Use the toolbar icons in top left. From top to bottom, these are:

Zoom/pan as per any other map type webapp.

To refresh your browser's copy of the markers, click the refresh icon.

To see this page, hit the question mark help icon.

To search for a marker by unique name substring, click the search icon. Type a substring. Click on a hit shown in the list.

To add a marker, click the marker icon. Click again where the marker should be put. A popup dialog box will ask for a unique identifier. Please use your kerberos userid, to allow the roster/mojo popup links to work. Use the pattern office-AIRPORT-CITY-NAME for offices. Or pick whatever will be useful to find your marker with the search function.

To move a marker, click the edit icon to enter edit mode. Drag misplaced markers. Click on "save" right beside the edit icon. Be rewarded by a popup containing git command output from the back-end. Click on "cancel" if you changed your mind.

To delete a marker, click the trash icon to enter delete mode. (It might be greyed out; you can still click on it.) Click on doomed markers. Click on "save" or "cancel".

How does it work?

Check it out.

The front-end consists of very small HTML + JavaScript files that load Leaflet and OSM data from the Internet into your browser. The front-end also loads marker data from our own servers via HTTP CGI. Markers may be created, edited (moved), and deleted; these operations also map to individual HTTP CGI calls to the server.

The back-end consists of bog-standard Apache HTTPD, a plain-text-file "database" containing the collected markers, and a few tiny CGI python scripts to relay the database to the web application. (Calling it a database is an exaggeration - it is literally a collection of text files, one per marker, whose contents are protected by GIT.)

There is really not much to it. No GIS database, no server processes, no fancy protocols. It took only about a day to get it working, after spending a few days scouting out many web-mapping-related software packages/services like postgis, cartodb, opengeo, mapbox, openlayers, google, etc. In this case, FOSS does the job, and easily.

Where to send patches?

Find gitmap sources at https://gitlab.cee.redhat.com/fche/gitmap.git. One or two third-party javascript libraries are stored there; others are served from upstream projects' external CDNs. Feel free to fork / experiment / deploy. Send patches to fche if desired.

Some hacking ideas:

  1. adding more marker metadata (full name, URLs)
  2. adding a toggle switch to turn marker clustering on/off
  3. taking a region-of-interest spec from the URL string (to make it easier to share maps already zoomed into a particular place)
Patches are welcome!

Please note that the version of the gitmap tree in gitlab.cee contains snapshots of the real live personal data RH folks have chosen to share. It is obviously confidential.