From 09ef30d42e44ce769c82f14d511a7f1115316a64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kim=20Minjoo=28=EA=B9=80=EB=AF=BC=EC=A3=BC/=EB=A6=AC?= =?UTF-8?q?=EB=B8=8C=29?= <131349867+Minjoo522@users.noreply.github.com> Date: Thu, 25 Jul 2024 10:51:36 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EC=BB=A4=EB=B0=8B=20=EB=A9=94=EC=8B=9C?= =?UTF-8?q?=EC=A7=80=20=EC=83=81=EB=8B=A8=20=ED=95=9C=20=EC=A4=84=EB=A7=8C?= =?UTF-8?q?=20=EC=82=AC=EC=9A=A9=ED=95=98=EB=8F=84=EB=A1=9D=20=EC=88=98?= =?UTF-8?q?=EC=A0=95=20(#143)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/backend_cd.yml | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/.github/workflows/backend_cd.yml b/.github/workflows/backend_cd.yml index 09b494b6..87540bf8 100644 --- a/.github/workflows/backend_cd.yml +++ b/.github/workflows/backend_cd.yml @@ -73,6 +73,11 @@ jobs: - deploy if: success() steps: + - name: Extract Commit Title + run: | + COMMIT_TITLE=$(echo "${{ github.event.head_commit.message }}" | head -n 1) + echo "COMMIT_TITLE=$COMMIT_TITLE" >> $GITHUB_ENV + - name: Build and Deploy Success uses: slackapi/slack-github-action@v1.24.0 with: @@ -85,7 +90,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": " \n 📣 Server Build & Deploy 결과를 안내 드립니다. 📣 \n\t • 🚀 Build Success \n\t • 🟢 Deploy Success \n\t • 🏷️ 관련 Commit: <${{ github.event.head_commit.url }}|${{ github.event.head_commit.message }}>" + "text": " \n 📣 Server Build & Deploy 결과를 안내 드립니다. 📣 \n\t • 🚀 Build Success \n\t • 🟢 Deploy Success \n\t • 🏷️ 관련 Commit: <${{ github.event.head_commit.url }}|${{ env.COMMIT_TITLE }}>" } } ] @@ -99,6 +104,11 @@ jobs: - build if: failure() steps: + - name: Extract Commit Title + run: | + COMMIT_TITLE=$(echo "${{ github.event.head_commit.message }}" | head -n 1) + echo "COMMIT_TITLE=$COMMIT_TITLE" >> $GITHUB_ENV + - name: Build Fail uses: slackapi/slack-github-action@v1.24.0 with: @@ -111,7 +121,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": " \n 📣 Server Build & Deploy 결과를 안내 드립니다. 📣 \n\t • 🔴 Build Fail \n\t • 🏷️ 관련 Commit: <${{ github.event.head_commit.url }}|${{ github.event.head_commit.message }}>" + "text": " \n 📣 Server Build & Deploy 결과를 안내 드립니다. 📣 \n\t • 🔴 Build Fail \n\t • 🏷️ 관련 Commit: <${{ github.event.head_commit.url }}|${{ env.COMMIT_TITLE }}>" } } ] @@ -125,6 +135,11 @@ jobs: - deploy if: failure() steps: + - name: Extract Commit Title + run: | + COMMIT_TITLE=$(echo "${{ github.event.head_commit.message }}" | head -n 1) + echo "COMMIT_TITLE=$COMMIT_TITLE" >> $GITHUB_ENV + - name: Deploy Fail uses: slackapi/slack-github-action@v1.24.0 with: @@ -137,7 +152,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": " \n 📣 Server Build & Deploy 결과를 안내 드립니다. 📣 \n\t • 🚀Build Success \n\t • 🔴Deploy Fail \n\t • 🏷️ 관련 Commit: <${{ github.event.head_commit.url }}|${{ github.event.head_commit.message }}>" + "text": " \n 📣 Server Build & Deploy 결과를 안내 드립니다. 📣 \n\t • 🚀Build Success \n\t • 🔴Deploy Fail \n\t • 🏷️ 관련 Commit: <${{ github.event.head_commit.url }}|${{ env.COMMIT_TITLE }}>" } } ]