Skip to content

docker-build-push-release #14

docker-build-push-release

docker-build-push-release #14

name: docker-build-push-release
on:
release:
types: [ released, edited ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Get release version without v
id: release_version
uses: battila7/get-version-action@v2
- name: Docker login
id: docker_login
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
- name: Build and push image
id: docker_build
uses: docker/build-push-action@v6
with:
push: true
tags: 3dcitydb/impexp:${{ steps.release_version.outputs.version-without-v }},3dcitydb/impexp:latest
build-args: |
IMPEXP_VERSION=${{ steps.release_version.outputs.version }}
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}
- name: Run container
run: docker run -t --rm 3dcitydb/impexp:${{ steps.release_version.outputs.version-without-v }} help | grep -i -E "Usage:"