Skip to content

Commit

Permalink
update action
Browse files Browse the repository at this point in the history
  • Loading branch information
Bricks666 committed Jan 27, 2024
1 parent 6515434 commit 3f12ba9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/publish-docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,9 @@ name: Docker
on:
push:
tags: [ 'v*.*.*' ]
branches: [ "main" ]
pull_request:
branches: [ "main", "develop" ]
release:
types: [ published ]


jobs:
Expand All @@ -29,11 +28,17 @@ jobs:
with:
images: bricks667/abctasks-server

- name: Extract package version
run: |
echo "TAG=$(jq -r '.version' package.json)" >> $GITHUB_ENV
- name: Build and push Docker image
uses: docker/build-push-action@3b5e8027fcad23fda98b2e3ac259d8d67585f671
with:
context: .
file: ./Dockerfile
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
tags: |
${{ steps.meta.outputs.tags }}
v${{ env.TAG }}
labels: ${{ steps.meta.outputs.labels }}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "server",
"version": "1.0.0",
"version": "2.2.1",
"description": "",
"main": "./dist/index.js",
"scripts": {
Expand Down

0 comments on commit 3f12ba9

Please sign in to comment.