Skip to content

Commit

Permalink
fix(create-release.yml): update Dockerfile reference from Dockerfile.…
Browse files Browse the repository at this point in the history
…slim to Dockerfile.alpine to match the actual file name

feat(create-release.yml): add support for building and pushing Docker image with Dockerfile.alpine to provide a lightweight Alpine-based image for Liquibase
  • Loading branch information
jandroav committed Sep 14, 2023
2 parents 9e15ce3 + 76df7c5 commit c3c4794
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ jobs:
- name: Update Dockerfile and commit changes
run: |
file_list=("Dockerfile" "Dockerfile.slim")
file_list=("Dockerfile" "Dockerfile.alpine")
LIQUIBASE_SHA=`curl -LsS https://github.com/liquibase/liquibase/releases/download/v${{ steps.collect-data.outputs.liquibaseVersion }}/liquibase-${{ steps.collect-data.outputs.liquibaseVersion }}.tar.gz | sha256sum | awk '{ print $1 }'`
for file in "${file_list[@]}"; do
sed -i 's/^ARG LIQUIBASE_VERSION=.*/ARG LIQUIBASE_VERSION='"${{ steps.collect-data.outputs.liquibaseVersion }}"'/' "${{ github.workspace }}/${file}"
Expand All @@ -94,7 +94,7 @@ jobs:
matrix:
image: [
{dockerfile: Dockerfile, name: liquibase/liquibase, suffix: ""},
{dockerfile: Dockerfile.slim, name: liquibase/liquibase, suffix: "-alpine"},
{dockerfile: Dockerfile.alpine, name: liquibase/liquibase, suffix: "-alpine"},
]
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -144,4 +144,4 @@ jobs:
no-cache: true
push: true
platforms: linux/amd64,linux/arm64
tags: ${{ matrix.image.name }}:latest${{ matrix.image.suffix }},${{ matrix.image.name }}:${{ needs.update-dockerfiles.outputs.extensionVersion }}${{ matrix.image.suffix }},${{ matrix.image.name }}:${{ needs.update-dockerfiles.outputs.minorVersion }}${{ matrix.image.suffix }},${{ env.ECR_REGISTRY }}:latest${{ matrix.image.suffix }},${{ env.ECR_REGISTRY }}:${{ needs.update-dockerfiles.outputs.extensionVersion }}${{ matrix.image.suffix }},${{ env.ECR_REGISTRY }}:${{ needs.update-dockerfiles.outputs.minorVersion }}${{ matrix.image.suffix }}
tags: ${{ matrix.image.name }}:latest${{ matrix.image.suffix }},${{ matrix.image.name }}:${{ needs.update-dockerfiles.outputs.extensionVersion }}${{ matrix.image.suffix }},${{ matrix.image.name }}:${{ needs.update-dockerfiles.outputs.minorVersion }}${{ matrix.image.suffix }},${{ env.ECR_REGISTRY }}:latest${{ matrix.image.suffix }},${{ env.ECR_REGISTRY }}:${{ needs.update-dockerfiles.outputs.extensionVersion }}${{ matrix.image.suffix }},${{ env.ECR_REGISTRY }}:${{ needs.update-dockerfiles.outputs.minorVersion }}${{ matrix.image.suffix }}

0 comments on commit c3c4794

Please sign in to comment.