Skip to content

added ability to off parameter and fix chunk height #2570

added ability to off parameter and fix chunk height

added ability to off parameter and fix chunk height #2570

name: build & publish dev snapshot image to ghcr.io
on:
push:
branches-ignore:
- master
- version-*
jobs:
build_and_publish_snapshot:
runs-on: ubuntu-20.04
steps:
- name: checkout
uses: actions/checkout@v4
- id: repo
name: resolve repository name
run: echo "::set-output name=REPOSITORY_NAME::$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')"
- id: branch
name: resolve branch name
run: echo ::set-output name=branch_name::${GITHUB_REF#refs/*/}
- id: version
name: resolve app version
uses: notiz-dev/github-action-json-property@release
with:
path: package.json
prop_path: version
- id: snapshot_name
name: resolve full snapshot version string
run: echo ::set-output name=value::"${{ steps.version.outputs.prop }}-${{ steps.branch.outputs.branch_name }}-${{ github.run_id }}"
- name: display snapshot version
run: echo ${{ steps.snapshot_name.outputs.value }}
- name: set up docker buildx plugin
uses: docker/setup-buildx-action@v3
- name: log in to github container registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: build image & push to registry
uses: docker/build-push-action@v6
with:
platforms: linux/amd64,linux/arm64
push: true
tags: ghcr.io/${{ github.repository }}:${{ steps.snapshot_name.outputs.value }}
labels: com.exactpro.th2.${{ steps.repo.outputs.REPOSITORY_NAME }}=${{ steps.version.outputs.prop }}