Skip to content

Commit

Permalink
update: add version retrieval step in release and publish workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
hardingadonis committed Jan 8, 2025
1 parent 34f3c5a commit 8849e25
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
3 changes: 1 addition & 2 deletions .github/actions/get-version/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ runs:
using: composite

steps:
- name: Get version
id: get_version
- name: Get version from script
run: |
wget https://raw.githubusercontent.com/lzaycoe/brainbox-deployment/refs/heads/main/scripts/get-version.sh
sudo apt-get install jq
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/release-and-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ jobs:
uses: actions/checkout@v4

- name: Get Version
id: get_version
uses: ./.github/actions/get-version

- name: Release
Expand All @@ -48,6 +49,7 @@ jobs:
uses: actions/checkout@v4

- name: Get Version
id: get_version
uses: ./.github/actions/get-version

- name: Login ghcr.io
Expand All @@ -59,7 +61,6 @@ jobs:

- name: Publish image
run: |
cd backend
docker buildx build . \
-t ghcr.io/${{ github.repository }}:${{ steps.get_version.outputs.version }} \
-t ghcr.io/${{ github.repository }}:latest \
Expand Down

0 comments on commit 8849e25

Please sign in to comment.