Skip to content

Commit

Permalink
Make Tile URL env variable (#36)
Browse files Browse the repository at this point in the history
  • Loading branch information
webb-ben authored Feb 6, 2025
1 parent 8b43d4d commit 0123a2e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
2 changes: 2 additions & 0 deletions default.env
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,5 @@ POSTGRES_PASSWORD=changeMe

# pygeoapi
PYGEOAPI_URL=http://localhost:5000
TILES_PATH=https://storage.googleapis.com/reference-tiles
TILES_SUFFIX="{z}/{x}/{y}.pbf"
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,6 @@ <h3>Tiles</h3>
.openOn(map);

clearHighlight();
console.log(e)
highlight = e.layer.properties.id || e.layer.properties.fid;
tilesPbfLayer.setFeatureStyle(highlight, {
weight: e.layer.options.weight + 3,
Expand Down
8 changes: 4 additions & 4 deletions pygeoapi.config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ resources:
- &tile_defaults
type: tile
name: MVT-tippecanoe
data: https://storage.googleapis.com/reference-tiles/hu08/{z}/{x}/{y}.pbf
data: ${TILES_PATH}/hu08/${TILES_SUFFIX:-}
options:
zoom:
min: 0
Expand Down Expand Up @@ -303,7 +303,7 @@ resources:
uri_field: uri
geom_field: geom
- <<: *tile_defaults
data: https://storage.googleapis.com/reference-tiles/hu10/{z}/{x}/{y}.pbf
data: ${TILES_PATH}/hu10/${TILES_SUFFIX:-}
nat_aq:
type: collection
title: USGS National Aquifers
Expand Down Expand Up @@ -539,7 +539,7 @@ resources:
predicate: 'schema:encodingFormat'
object: '?distributionFormat'
- <<: *tile_defaults
data: https://storage.googleapis.com/reference-tiles/mainstems/{z}/{x}/{y}.pbf
data: ${TILES_PATH}/mainstems/${TILES_SUFFIX:-}

dams: # updated 2024-04-23
type: collection
Expand Down Expand Up @@ -695,7 +695,7 @@ resources:
uri_field: uri
geom_field: geom
- <<: *tile_defaults
data: https://storage.googleapis.com/reference-tiles/counties/{z}/{x}/{y}.pbf
data: ${TILES_PATH}/counties/${TILES_SUFFIX:-}
aiannh:
type: collection
title: American Indian/Alaska Native Areas/Hawaiian Home Lands (AIANNH)
Expand Down

0 comments on commit 0123a2e

Please sign in to comment.