Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/chartpress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- 'main'
- 'staging'
- '1247_tilejson'
jobs:
build:
runs-on: ubuntu-22.04
Expand Down
34 changes: 29 additions & 5 deletions images/tiler-server/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,28 @@
FROM gospatial/tegola:v0.21.2
FROM golang:1.25.5-alpine AS builder

# Install build dependencies
RUN apk add --no-cache \
git \
make \
bash \
nodejs \
npm

# Clone and build tegola from fork
WORKDIR /build
RUN git clone https://github.com/OpenHistoricalMap/tegola.git . && git checkout 6325b105ffdb435c1fca22d6185f96cdaabebac0

# Build arguments for version information
ARG BUILD_PKG="github.com/go-spatial/tegola/internal/build"
RUN echo "Generating UI files..." && \
go generate ./server && \
echo "Building tegola binary..." && \
cd cmd/tegola && \
go build -mod vendor \
-ldflags "-w -X '${BUILD_PKG}.Version=${VER}' -X '${BUILD_PKG}.GitRevision=${REVISION}' -X '${BUILD_PKG}.GitBranch=${BRANCH}'" \
-o /usr/local/bin/tegola

FROM alpine:latest

RUN apk add --no-cache \
python3 \
Expand All @@ -12,20 +36,20 @@ RUN apk add --no-cache \
jq \
procps \
dcron \
ca-certificates \
&& apk add --no-cache --virtual .build-deps \
gcc \
libffi-dev \
musl-dev \
openssl-dev \
python3-dev \
py3-pip \
&& pip install --upgrade pip \
&& pip install awscli mercantile requests boto3 psycopg2-binary \
&& pip install --break-system-packages --upgrade pip \
&& pip install --break-system-packages awscli mercantile requests boto3 psycopg2-binary \
&& apk del .build-deps \
&& rm -rf /root/.cache /var/cache/apk/*

# Symlink tegola binary for easier access
RUN ln -s /opt/tegola /usr/bin/tegola
COPY --from=builder /usr/local/bin/tegola /usr/local/bin/tegola
WORKDIR /app
COPY . .
ENTRYPOINT ["/bin/bash", "-c"]
Expand Down
4 changes: 2 additions & 2 deletions images/tiler-server/config/config.template.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ type = "prometheus"
## OpenHistoricalMap providers
####################################
[[providers]]
name = "osm"
name = "ohm"
type = "mvt_postgis"
uri = "postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB}"
max_connections = 150
Expand Down Expand Up @@ -118,7 +118,7 @@ max_connections = 25
## OpenHistoricalMap maps
####################################
[[maps]]
name = "osm"
name = "ohm"
attribution = "OpenHistoricalMap"
center = [-42.31214, 70.00455, 10.0]
###### MAPS_OSM
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -175,42 +175,42 @@ WHERE geometry && !BBOX!
#######Maps
[[maps.layers]]
name = "land_ohm_centroids"
provider_layer = "osm.admin_boundaries_centroid_z0_2"
provider_layer = "ohm.admin_boundaries_centroid_z0_2"
min_zoom = 0
max_zoom = 2

[[maps.layers]]
name = "land_ohm_centroids"
provider_layer = "osm.admin_boundaries_centroid_z3_5"
provider_layer = "ohm.admin_boundaries_centroid_z3_5"
min_zoom = 3
max_zoom = 5

[[maps.layers]]
name = "land_ohm_centroids"
provider_layer = "osm.admin_boundaries_centroid_z6_7"
provider_layer = "ohm.admin_boundaries_centroid_z6_7"
min_zoom = 6
max_zoom = 7

[[maps.layers]]
name = "land_ohm_centroids"
provider_layer = "osm.admin_boundaries_centroid_z8_9"
provider_layer = "ohm.admin_boundaries_centroid_z8_9"
min_zoom = 8
max_zoom = 9

[[maps.layers]]
name = "land_ohm_centroids"
provider_layer = "osm.admin_boundaries_centroid_z10_12"
provider_layer = "ohm.admin_boundaries_centroid_z10_12"
min_zoom = 10
max_zoom = 12

[[maps.layers]]
name = "land_ohm_centroids"
provider_layer = "osm.admin_boundaries_centroid_z13_15"
provider_layer = "ohm.admin_boundaries_centroid_z13_15"
min_zoom = 13
max_zoom = 15

[[maps.layers]]
name = "land_ohm_centroids"
provider_layer = "osm.admin_boundaries_centroid_z16_20"
provider_layer = "ohm.admin_boundaries_centroid_z16_20"
min_zoom = 16
max_zoom = 20
14 changes: 7 additions & 7 deletions images/tiler-server/config/providers/admin_boundaries_lines.toml
Original file line number Diff line number Diff line change
Expand Up @@ -148,42 +148,42 @@ WHERE
#######Maps
[[maps.layers]]
name = "land_ohm_lines"
provider_layer = "osm.admin_boundaries_lines_z0_2"
provider_layer = "ohm.admin_boundaries_lines_z0_2"
min_zoom = 0
max_zoom = 2

[[maps.layers]]
name = "land_ohm_lines"
provider_layer = "osm.admin_boundaries_lines_z3_5"
provider_layer = "ohm.admin_boundaries_lines_z3_5"
min_zoom = 3
max_zoom = 5

[[maps.layers]]
name = "land_ohm_lines"
provider_layer = "osm.admin_boundaries_lines_z6_7"
provider_layer = "ohm.admin_boundaries_lines_z6_7"
min_zoom = 6
max_zoom = 7

[[maps.layers]]
name = "land_ohm_lines"
provider_layer = "osm.admin_boundaries_lines_z8_9"
provider_layer = "ohm.admin_boundaries_lines_z8_9"
min_zoom = 8
max_zoom = 9

[[maps.layers]]
name = "land_ohm_lines"
provider_layer = "osm.admin_boundaries_lines_z10_12"
provider_layer = "ohm.admin_boundaries_lines_z10_12"
min_zoom = 10
max_zoom = 12

[[maps.layers]]
name = "land_ohm_lines"
provider_layer = "osm.admin_boundaries_lines_z13_15"
provider_layer = "ohm.admin_boundaries_lines_z13_15"
min_zoom = 13
max_zoom = 15

[[maps.layers]]
name = "land_ohm_lines"
provider_layer = "osm.admin_boundaries_lines_z16_20"
provider_layer = "ohm.admin_boundaries_lines_z16_20"
min_zoom = 16
max_zoom = 20
Original file line number Diff line number Diff line change
Expand Up @@ -76,18 +76,18 @@ WHERE
#######Maps
[[maps.layers]]
name = "land_ohm_maritime"
provider_layer = "osm.admin_lines_z0_5"
provider_layer = "ohm.admin_lines_z0_5"
min_zoom = 0
max_zoom = 5

[[maps.layers]]
name = "land_ohm_maritime"
provider_layer = "osm.admin_lines_z6_9"
provider_layer = "ohm.admin_lines_z6_9"
min_zoom = 6
max_zoom = 9

[[maps.layers]]
name = "land_ohm_maritime"
provider_layer = "osm.admin_lines_z10_15"
provider_layer = "ohm.admin_lines_z10_15"
min_zoom = 10
max_zoom = 12
4 changes: 2 additions & 2 deletions images/tiler-server/config/providers/amenity_areas.toml
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ WHERE
#######Maps
[[maps.layers]]
name = "amenity_areas"
provider_layer = "osm.amenity_areas_z14_15"
provider_layer = "ohm.amenity_areas_z14_15"
min_zoom = 14
max_zoom = 15

[[maps.layers]]
name = "amenity_areas"
provider_layer = "osm.amenity_areas_z16_20"
provider_layer = "ohm.amenity_areas_z16_20"
min_zoom = 16
max_zoom = 20
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ WHERE
#######Maps
[[maps.layers]]
name = "amenity_points_centroids"
provider_layer = "osm.amenity_points_centroids_z14_15"
provider_layer = "ohm.amenity_points_centroids_z14_15"
min_zoom = 14
max_zoom = 15

[[maps.layers]]
name = "amenity_points_centroids"
provider_layer = "osm.amenity_points_centroids_z16_20"
provider_layer = "ohm.amenity_points_centroids_z16_20"
min_zoom = 16
max_zoom = 20
4 changes: 2 additions & 2 deletions images/tiler-server/config/providers/buildings_areas.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ WHERE
#######Maps
[[maps.layers]]
name = "buildings"
provider_layer = "osm.buildings_z14_15"
provider_layer = "ohm.buildings_z14_15"
min_zoom = 14
max_zoom = 15

[[maps.layers]]
name = "buildings"
provider_layer = "osm.buildings_z16_20"
provider_layer = "ohm.buildings_z16_20"
min_zoom = 16
max_zoom = 20
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@ WHERE

[[maps.layers]]
name = "buildings_points_centroids"
provider_layer = "osm.buildings_points_centroids_z14_15"
provider_layer = "ohm.buildings_points_centroids_z14_15"
min_zoom = 14
max_zoom = 15

[[maps.layers]]
name = "buildings_points_centroids"
provider_layer = "osm.buildings_points_centroids_z16_20"
provider_layer = "ohm.buildings_points_centroids_z16_20"
min_zoom = 16
max_zoom = 20
10 changes: 5 additions & 5 deletions images/tiler-server/config/providers/landuse_areas.toml
Original file line number Diff line number Diff line change
Expand Up @@ -128,30 +128,30 @@ WHERE

[[maps.layers]]
name = "landuse_areas"
provider_layer = "osm.landuse_areas_z6_7"
provider_layer = "ohm.landuse_areas_z6_7"
min_zoom = 6
max_zoom = 7

[[maps.layers]]
name = "landuse_areas"
provider_layer = "osm.landuse_areas_z8_9"
provider_layer = "ohm.landuse_areas_z8_9"
min_zoom = 8
max_zoom = 9

[[maps.layers]]
name = "landuse_areas"
provider_layer = "osm.landuse_areas_z10_12"
provider_layer = "ohm.landuse_areas_z10_12"
min_zoom = 10
max_zoom = 12

[[maps.layers]]
name = "landuse_areas"
provider_layer = "osm.landuse_areas_z13_15"
provider_layer = "ohm.landuse_areas_z13_15"
min_zoom = 13
max_zoom = 15

[[maps.layers]]
name = "landuse_areas"
provider_layer = "osm.landuse_areas_z16_20"
provider_layer = "ohm.landuse_areas_z16_20"
min_zoom = 16
max_zoom = 20
4 changes: 2 additions & 2 deletions images/tiler-server/config/providers/landuse_lines.toml
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ WHERE

[[maps.layers]]
name = "landuse_lines"
provider_layer = "osm.landuse_lines_z14_15"
provider_layer = "ohm.landuse_lines_z14_15"
min_zoom = 14
max_zoom = 15

[[maps.layers]]
name = "landuse_lines"
provider_layer = "osm.landuse_lines_z16_20"
provider_layer = "ohm.landuse_lines_z16_20"
min_zoom = 16
max_zoom = 20

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,30 +124,30 @@ WHERE

[[maps.layers]]
name = "landuse_points_centroids"
provider_layer = "osm.landuse_points_centroids_z6_7"
provider_layer = "ohm.landuse_points_centroids_z6_7"
min_zoom = 6
max_zoom = 7

[[maps.layers]]
name = "landuse_points_centroids"
provider_layer = "osm.landuse_points_centroids_z8_9"
provider_layer = "ohm.landuse_points_centroids_z8_9"
min_zoom = 8
max_zoom = 9

[[maps.layers]]
name = "landuse_points_centroids"
provider_layer = "osm.landuse_points_centroids_z10_12"
provider_layer = "ohm.landuse_points_centroids_z10_12"
min_zoom = 10
max_zoom = 12

[[maps.layers]]
name = "landuse_points_centroids"
provider_layer = "osm.landuse_points_centroids_z13_15"
provider_layer = "ohm.landuse_points_centroids_z13_15"
min_zoom = 13
max_zoom = 15

[[maps.layers]]
name = "landuse_points_centroids"
provider_layer = "osm.landuse_points_centroids_z16_20"
provider_layer = "ohm.landuse_points_centroids_z16_20"
min_zoom = 16
max_zoom = 20
8 changes: 4 additions & 4 deletions images/tiler-server/config/providers/other_areas.toml
Original file line number Diff line number Diff line change
Expand Up @@ -97,25 +97,25 @@ WHERE

[[maps.layers]]
name = "other_areas"
provider_layer = "osm.other_areas_z8_9"
provider_layer = "ohm.other_areas_z8_9"
min_zoom = 8
max_zoom = 9

[[maps.layers]]
name = "other_areas"
provider_layer = "osm.other_areas_z10_12"
provider_layer = "ohm.other_areas_z10_12"
min_zoom = 10
max_zoom = 12

[[maps.layers]]
name = "other_areas"
provider_layer = "osm.other_areas_z13_15"
provider_layer = "ohm.other_areas_z13_15"
min_zoom = 13
max_zoom = 15

[[maps.layers]]
name = "other_areas"
provider_layer = "osm.other_areas_z16_20"
provider_layer = "ohm.other_areas_z16_20"
min_zoom = 16
max_zoom = 20

4 changes: 2 additions & 2 deletions images/tiler-server/config/providers/other_lines.toml
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ WHERE
#######Maps
[[maps.layers]]
name = "other_lines"
provider_layer = "osm.other_lines_z14_15"
provider_layer = "ohm.other_lines_z14_15"
min_zoom = 14
max_zoom = 15

[[maps.layers]]
name = "other_lines"
provider_layer = "osm.other_lines_z16_20"
provider_layer = "ohm.other_lines_z16_20"
min_zoom = 16
max_zoom = 20
Loading
Loading