Skip to content

Commit a82c02b

Browse files
committed
Ensure text file exists for detection by slack notification resource.
Restore conditional notifications after logic was changed in cloudfoundry-community/slack-notification-resource#47.
1 parent 88433a2 commit a82c02b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

terraform-apply.sh

+2
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@ if [ "${TERRAFORM_ACTION}" = "plan" ]; then
3535
"${DIR}"
3636

3737
# Write a sentinel value; pipelines can alert to slack if set using `text_file`
38+
# Ensure that slack notification resource detects text file
39+
touch ./terraform-state/message.txt
3840
if ! ${TERRAFORM} show ./terraform-state/terraform.tfplan | grep 'This plan does nothing.' ; then
3941
echo "sentinel" > ./terraform-state/message.txt
4042
fi

0 commit comments

Comments
 (0)