Merge pull request #68 from Try-AngIe/feat/product #16
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: FE PIPELINE | |
on: | |
push: | |
branches: | |
- dev | |
paths: | |
- 'client/**' | |
permissions: #github actions bot에게 권한 열기 | |
contents: write | |
pages: write | |
id-token: write | |
jobs: | |
fe-pipeline: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Git Config | |
run: | | |
git config --global user.name 'github-actions[bot]' | |
git config --global user.email 'github-actions[bot]@users.noreply.github.com' | |
- name: LOG | |
run: | | |
timestamp=$(date +"%Y-%m-%d_%H-%M-%S") | |
log_file="DEPLOY_LOG/client/FE_CD_LOG-$timestamp.log" | |
mkdir -p DEPLOY_LOG/client | |
echo "프론트엔드 배포 로그" >> "$log_file" | |
git fetch origin | |
git checkout prod || git checkout -b prod | |
git add "$log_file" | |
git commit -m "release: $timestamp FE 배포 완료" | |
git push origin prod --force |