Skip to content

Commit

Permalink
feat(deploy): merge deploy with build
Browse files Browse the repository at this point in the history
  • Loading branch information
bezysoftware committed Oct 5, 2024
1 parent 9caff83 commit 1d171f1
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 57 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/build-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Build & Deploy

on:
push:
branches: [ main ]
pull_request:

jobs:
build:
Expand Down Expand Up @@ -36,8 +36,14 @@ jobs:
- name: Get docker tag
id: tag
run: echo "IMAGE_TAG=latest" >> $GITHUB_OUTPUT

run: |
echo "${GITHUB_REF##*/}"
if [[ "${GITHUB_REF##*/}" == "main" ]]; then
echo "IMAGE_TAG=latest" >> $GITHUB_OUTPUT
else
echo "IMAGE_TAG=${GITHUB_REF##*/}" >> $GITHUB_OUTPUT
fi
- name: Build and push
id: docker_build
uses: docker/build-push-action@v6
Expand Down
53 changes: 0 additions & 53 deletions .github/workflows/build.yml

This file was deleted.

1 change: 0 additions & 1 deletion Netstr.sln
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{320F094E-4B63-40D7-8D8B-AB5B01F6FCB0}"
ProjectSection(SolutionItems) = preProject
.github\workflows\build-deploy.yml = .github\workflows\build-deploy.yml
.github\workflows\build.yml = .github\workflows\build.yml
.github\workflows\manual.yml = .github\workflows\manual.yml
.github\workflows\release.yml = .github\workflows\release.yml
EndProjectSection
Expand Down

0 comments on commit 1d171f1

Please sign in to comment.