update libpostal to get kosovo #64
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and publish Docker image | |
on: | |
push: | |
branches: | |
- "master" | |
tags: | |
- "v*" | |
env: | |
DOCKER_IMAGE_BASENAME: ghcr.io/osm-without-borders/cosmogony | |
DOCKER_BUILDKIT: 1 | |
jobs: | |
build_docker: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: true | |
- name: Login to container registry | |
uses: docker/login-action@v1 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Get image name | |
run: | | |
VERSION=${GITHUB_REF#refs/*/} | |
if [ "$VERSION" == "master" ]; then | |
IMAGE_TAG=latest | |
else | |
IMAGE_TAG=$VERSION | |
fi | |
echo "DOCKER_IMAGE=$DOCKER_IMAGE_BASENAME:$IMAGE_TAG" >> $GITHUB_ENV | |
- run: docker build --label "org.label-schema.vcs-ref=$GITHUB_SHA" -t $DOCKER_IMAGE . | |
- run: docker push $DOCKER_IMAGE |