Skip to content

Commit 196e814

Browse files
committed
fix: 스크립트 출력 방식 수정
1 parent e981977 commit 196e814

File tree

1 file changed

+19
-13
lines changed

1 file changed

+19
-13
lines changed

.github/workflows/terraform-plan.yml

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,12 @@ jobs:
4747
resource_summary=$(grep -E '^(# | [~+\-])' plan_full.txt | head -n 50)
4848
plan_summary=$(grep -E '^Plan:' plan_full.txt)
4949
50-
echo "summary_output<<EOF" >> $GITHUB_OUTPUT
51-
echo "$resource_summary" >> $GITHUB_OUTPUT
52-
echo "$plan_summary" >> $GITHUB_OUTPUT
53-
echo "EOF" >> $GITHUB_OUTPUT
50+
{
51+
echo "summary_output<<EOF"
52+
echo "$resource_summary"
53+
echo "$plan_summary"
54+
echo "EOF"
55+
} >> "$GITHUB_OUTPUT"
5456
5557
if [ "$exit_code" -eq 0 ]; then
5658
echo "✅ Terraform plan completed with no changes."
@@ -111,10 +113,12 @@ jobs:
111113
resource_summary=$(grep -E '^(# | [~+\-])' plan_full.txt | head -n 50)
112114
plan_summary=$(grep -E '^Plan:' plan_full.txt)
113115
114-
echo "summary_output<<EOF" >> $GITHUB_OUTPUT
115-
echo "$resource_summary" >> $GITHUB_OUTPUT
116-
echo "$plan_summary" >> $GITHUB_OUTPUT
117-
echo "EOF" >> $GITHUB_OUTPUT
116+
{
117+
echo "summary_output<<EOF"
118+
echo "$resource_summary"
119+
echo "$plan_summary"
120+
echo "EOF"
121+
} >> "$GITHUB_OUTPUT"
118122
119123
if [ "$exit_code" -eq 0 ]; then
120124
echo "✅ Terraform plan completed with no changes."
@@ -175,10 +179,12 @@ jobs:
175179
resource_summary=$(grep -E '^(# | [~+\-])' plan_full.txt | head -n 50)
176180
plan_summary=$(grep -E '^Plan:' plan_full.txt)
177181
178-
echo "summary_output<<EOF" >> $GITHUB_OUTPUT
179-
echo "$resource_summary" >> $GITHUB_OUTPUT
180-
echo "$plan_summary" >> $GITHUB_OUTPUT
181-
echo "EOF" >> $GITHUB_OUTPUT
182+
{
183+
echo "summary_output<<EOF"
184+
echo "$resource_summary"
185+
echo "$plan_summary"
186+
echo "EOF"
187+
} >> "$GITHUB_OUTPUT"
182188
183189
if [ "$exit_code" -eq 0 ]; then
184190
echo "✅ Terraform plan completed with no changes."
@@ -206,7 +212,7 @@ jobs:
206212
comment-summary:
207213
name: "Comment PR with Plan Summary"
208214
runs-on: ubuntu-latest
209-
needs: [plan-common, plan-dev, plan-prod]
215+
needs: [ plan-common, plan-dev, plan-prod ]
210216
if: always()
211217
steps:
212218
- name: Comment PR with Plan Summary

0 commit comments

Comments
 (0)