diff --git a/.github/workflows/publish-pmtiles.yml b/.github/workflows/publish-pmtiles.yml index a736127..b4fe953 100644 --- a/.github/workflows/publish-pmtiles.yml +++ b/.github/workflows/publish-pmtiles.yml @@ -175,7 +175,7 @@ jobs: docker-image: ghcr.io/govlt/national-boundaries-vector docker-context: vector/docker/static file: vector/docker/static/Dockerfile - environment: ${{ (startsWith(github.ref, 'refs/tags/') && !contains(github.ref, 'pre')) && 'stable' || 'preview' }} + environment: ${{ startsWith(github.ref, 'refs/tags/') && 'stable' || 'preview' }} no-cache: true push: true cache-from: '' diff --git a/README.md b/README.md index 50e2611..be9c233 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,8 @@ Use hosted versions of boundaries on your website, with global low latency and h ### Self-Hosting +#### PMTiles + Download the latest PMTiles archives and host them on your own server. | Type | Lithuanian Translation | PMTiles Archive URL | @@ -41,6 +43,33 @@ Download the latest PMTiles archives and host them on your own server. | **Streets** | Gatvių ribos | [streets.pmtiles](https://github.com/govlt/national-boundaries/releases/latest/download/streets.pmtiles) | | **Parcels** | Žemės sklypų ribos | [parcels.pmtiles](https://github.com/govlt/national-boundaries/releases/latest/download/parcels.pmtiles)
(**Important:** visible from zoom level 14) | +Ensure to periodically download the PMTiles archives mentioned above to +your own S3 or file storage and utilize them as needed. + +#### Docker Vector Tiles + +Utilize the provided Docker +image [national-boundaries-vector](https://github.com/govlt/national-boundaries/pkgs/container/national-boundaries-vector), +which includes all PMTiles enabling you to serve vector tiles on-the-fly. + +Here's an example of its usage with Docker Compose: + +```yaml +services: + national-boundaries-vector: + image: ghcr.io/govlt/national-boundaries-vector:stable + pull_policy: always + restart: unless-stopped + ports: + - "80:80" + healthcheck: + test: [ "CMD-SHELL", "wget --no-verbose --tries=1 --spider http://127.0.0.1:80/health || exit 1" ] + interval: 5s + timeout: 3s + start_period: 5s + retries: 5 +``` + ## Architecture ```mermaid diff --git a/vector/docker/static/Dockerfile b/vector/docker/static/Dockerfile index bf1b769..2a3c3bc 100644 --- a/vector/docker/static/Dockerfile +++ b/vector/docker/static/Dockerfile @@ -2,8 +2,6 @@ FROM caddy:2.8 EXPOSE 80 -HEALTHCHECK --interval=30s --timeout=5s --start-period=5s --retries=3 CMD wget -qO- http://127.0.0.1:80/health || exit 1 - # Copy Caddyfile COPY ./caddy/Caddyfile /etc/caddy/Caddyfile