{"id":13397502,"url":"https://github.com/mapbox/osm-bright","last_synced_at":"2025-03-14T00:32:25.677Z","repository":{"id":1221083,"uuid":"1139339","full_name":"mapbox/osm-bright","owner":"mapbox","description":"A Carto template for OpenStreetMap data","archived":false,"fork":false,"pushed_at":"2020-11-24T19:10:35.000Z","size":1470,"stargazers_count":698,"open_issues_count":53,"forks_count":224,"subscribers_count":149,"default_branch":"master","last_synced_at":"2024-07-31T18:20:36.115Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"CartoCSS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mapbox.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2010-12-05T00:12:26.000Z","updated_at":"2024-07-24T20:05:12.000Z","dependencies_parsed_at":"2022-08-16T12:35:27.646Z","dependency_job_id":null,"html_url":"https://github.com/mapbox/osm-bright","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mapbox%2Fosm-bright","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mapbox%2Fosm-bright/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mapbox%2Fosm-bright/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mapbox%2Fosm-bright/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mapbox","download_url":"https://codeload.github.com/mapbox/osm-bright/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243504767,"owners_count":20301502,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-30T18:01:27.350Z","updated_at":"2025-03-14T00:32:24.995Z","avatar_url":"https://github.com/mapbox.png","language":"CartoCSS","readme":"OSM Bright\n==========\n\n![screenshot](https://raw.github.com/mapbox/osm-bright/master/preview.png)\n\nOSM Bright is a sensible starting point for quickly making beautiful maps based\non an OpenStreetMap database. It is written in the [Carto][] styling language\nand can be opened as a project in [TileMill][].\n\nThe style is still a work in progress and you are encouraged to use the\n[issue tracker][] to note missing features or problems with the current\nimplementation. \n\n[Carto]: http://github.com/mapbox/carto/\n[TileMill]: https://www.mapbox.com/tilemill/\n[issue tracker]: http://github.com/mapbox/osm-bright/issues/\n\n### Quickstart\n\n* [Mac OS X Quickstart](https://www.mapbox.com/tilemill/docs/guides/osm-bright-mac-quickstart/)\n* [Ubuntu Quickstart](https://www.mapbox.com/tilemill/docs/guides/osm-bright-ubuntu-quickstart/)\n\nSetup Instructions\n------------------\n\n### 1. Download shapefiles\n\nOSM Bright depends on two large shapefiles. You will need to download and extract them before continuing. \n\nDownload them to the `shp` directory in the osm-bright folder. You can do this with `wget` like:\n\n    wget http://data.openstreetmapdata.com/simplified-land-polygons-complete-3857.zip\n    wget http://data.openstreetmapdata.com/land-polygons-split-3857.zip\n\nIf you are going to use the osm2pqsql style you will need another (but smaller shapefile)\n    wget http://mapbox-geodata.s3.amazonaws.com/natural-earth-1.4.0/cultural/10m-populated-places-simple.zip\n\nOnce downloaded, extract them from their zip files. \n\n### 2. Run the shapefiles through shapeindex\n\nShapeindex is a tool that improves performance for shapefiles in Tilemill. \n\nMac and Linux users already have Shapeindex installed through Tilemill but Windows users will need to download [Shapeindex for Windows][] before continuing. \n\nTo run Shapeindex on Mac and Linux, go to the terminal, move to the shp directory of osm-bright, run shapeindex in each shp subdirectory like: \n\n    shapeindex land-polygons-split-3857.shp\n\n[Shapeindex for Windows]: http://mapnik.s3.amazonaws.com/dist/archive/shapeindex-2.2.0-win-x86_32.zip\n\n### 3. Set up PostgreSQL \u0026 PostGIS ###\n\nIf you don't already, you need to have [PostgreSQL][] installed \u0026 running with\na [PostGIS][] database setup within it. See the [PostGIS documentation][1] for\nfull information on how to do this.\n\n[PostgreSQL]: http://postgresql.org/\n[PostGIS]: http://postgis.refractions.net/\n[1]: http://postgis.net/documentation\n\n### 4. Import OpenStreetMap data ###\n\nYou will need an OSM database extract in one of the following formats:\n\n- .osm.pbf (binary; smallest \u0026 fastest)\n- .osm.bz2 (compressed xml)\n- .osm (xml)\n\nYou can find appropriate data extracts for a variety of regions at\n\u003chttp://download.geofabrik.de\u003e or \u003chttps://mapzen.com/metro-extracts/\u003e. See\n[the OSM wiki][2] for information about (very large) full-planet downloads.\n\nYou need to process this data and import it to your PostGIS database. You can\ndo this with either [Imposm][] or [osm2pgsql][]; see their respective websites\nfor installation instructions.\n\n#### Using Imposm\n\nIf you are using Imposm, you should use the [included mapping configuration][4]\nwhich includes a few important tags compared to the default. The Imposm import \ncommand looks like this:\n\n    imposm -U \u003cpostgres_user\u003e -d \u003cpostgis_database\u003e \\\n      -m /path/to/osm-bright/imposm-mapping.py --read --write \\\n      --optimize --deploy-production-tables \u003cdata.osm.pbf\u003e\n\nSee `imposm --help` or the [online documentation][3] for more details.\n\n#### Using osm2pgsql\n\nIf you are using osm2pgsql the default style file should work well. The \nosm2pgsql import command looks like this:\n\n    osm2pgsql -c -G -U \u003cpostgres_user\u003e -d \u003cpostgis_database\u003e \u003cdata.osm.pbf\u003e\n\nSee `man osm2pgsql` or the [online documentation][5] for more details.\n\n[2]: http://wiki.openstreetmap.org/wiki/Planet\n[Imposm]: http://imposm.org/\n[3]: http://imposm.org/\n[4]: https://github.com/mapbox/osm-bright/blob/master/imposm-mapping.py\n[osm2pgsql]: http://wiki.openstreetmap.org/wiki/Osm2pgsql\n[5]: http://wiki.openstreetmap.org/wiki/Osm2pgsql\n\n### 5. Edit the configuration ###\n\nYou'll need to adjust some settings for things like your PostgreSQL connection\ninformation.\n\n1. Make a copy of `configure.py.sample` and name it `configure.py`.\n\n    cp configure.py.sample configure.py\n\n2. Open `configure.py` in a text editor.\n3. Make sure the \"importer\" option matches the program you used to import your \n   data (either \"imposm\" or \"osm2pgsql\").\n4. Optionally change the name of your project from the default, 'OSM Bright'.\n5. Adjust, if needed, the path to point to your MapBox project folder.\n6. Make any adjustments to the PostgreSQL connection settings. Your database\n   may be set up so that you require a password or different user name.\n7. Optionally adjust the query extents or shapefile locations. (Refer to the \n   comments in the configuration file for more information.)\n8. Save \u0026 close the file.\n\n### 6. Run make.py ###\n\n    ./make.py\n\nThis will create a new folder called \"build\" with your new project, customized\nwith the variables you set in `configure.py` and install a copy of this build\nto your MapBox project folder. If you open up TileMill you should see your new\nmap in the project listing.\n\nClick on the map to view it in the editing interface.\n\n### IMPORTANT\n\nHave patience: the first time the project opens it needs to download very large\nshapefiles before the map can render. This can take 5-10 minutes on a fast\nconnection and longer on a slow connection. Keep TileMill open and feel free to\nnavigate back to the projects view then back to the project editor view to check\non its loading status. You can also check the TileMill logs to see the download\nstatus of the remote files.\n\nOnce the map tiles show up, you're now ready to start editing the template in TileMill!\n","funding_links":[],"categories":["CartoCSS"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmapbox%2Fosm-bright","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmapbox%2Fosm-bright","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmapbox%2Fosm-bright/lists"}