Skip to content

stub in workflow

stub in workflow #2

name: Convert mbtiles to pmtiles
on:
workflow_dispatch:
pull_request:
jobs:
build:
runs-on: ubuntu-latest
env:
AREA: nova-scotia
steps:
# - name: Maximize build space
# uses: AdityaGarg8/remove-unwanted-software@v2
# with:
# remove-android: 'true'
# remove-dotnet: 'true'
# remove-haskell: 'true'
# remove-codeql: 'true'
# remove-docker-images: 'true'
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- name: Fetch binaries
run: sudo mkdir /mnt/output && sudo chown runner:docker /mnt/output && wget --progress=dot:giga https://github.com/protomaps/go-pmtiles/releases/download/v1.13.0/go-pmtiles_1.13.0_Linux_x86_64.tar.gz && tar xvf go-pmtiles*
- name: Fetch tiles
env:
AWS_ENDPOINT_URL: https://ce5627cfc65c8b54d40bb91c0ba7298b.r2.cloudflarestorage.com
AWS_EC2_METADATA_DISABLED: true
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
run: aws s3 cp s3://hikes-public/"$AREA".mbtiles . --no-progress
- name: pmtiles convert
run: ./pmtiles convert "$AREA".mbtiles /mnt/output/"$AREA".pmtiles
- name: Upload tiles
env:
AWS_ENDPOINT_URL: https://ce5627cfc65c8b54d40bb91c0ba7298b.r2.cloudflarestorage.com
AWS_EC2_METADATA_DISABLED: true
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
run: aws s3 cp --no-progress /mnt/output/"$AREA".pmtiles s3://hikes-public/"$AREA".pmtiles