Skip to content

Commit

Permalink
chore: release cd를 돌릴 수 있는 브랜치 한정
Browse files Browse the repository at this point in the history
  • Loading branch information
nayonsoso committed Dec 13, 2024
1 parent 35d7530 commit edd14d9
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/backend-prod-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,17 @@ env:
APPLICATION_DIRECTORY: /home/ubuntu/review-me

jobs:
check-branch:
name: Check branch name
runs-on: ubuntu-latest
steps:
- name: Check branch name
if: ${{ github.ref_name != 'release' && !startsWith(github.ref_name, 'hotfix/') }}
run: |
echo "This workflow can only run on 'release' branch or branches starting with 'hotfix/'"
echo "Current branch: ${{ github.ref_name }}"
exit 1
build:
name: Build Dockerfile and push to DockerHub
runs-on: ubuntu-latest
Expand Down

0 comments on commit edd14d9

Please sign in to comment.