From e019b3340a80c727c9278d649ff9569dc5be0dbc Mon Sep 17 00:00:00 2001 From: "David W.H. Swenson" Date: Mon, 30 Mar 2026 17:23:05 -0500 Subject: [PATCH] Use bash, not sh, for local-exec interpreter This had worked fine locally, where I guess `sh` is symlinked to `bash`. However, real `sh` doesn't allow the `set -o pipefail`, so we need to use bash for this to deploy correctly in GitHub Actions. --- modules/lambda-image-build/main.tf | 2 +- modules/lambda-image-public/main.tf | 2 +- modules/lambda-image-republish/main.tf | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/lambda-image-build/main.tf b/modules/lambda-image-build/main.tf index 33e32ef..38a4519 100644 --- a/modules/lambda-image-build/main.tf +++ b/modules/lambda-image-build/main.tf @@ -106,7 +106,7 @@ resource "null_resource" "build_and_push" { } provisioner "local-exec" { - interpreter = ["/bin/sh", "-c"] + interpreter = ["/bin/bash", "-c"] command = <<-EOC set -euo pipefail # Use an ephemeral Docker config to avoid host keychain credential helper conflicts. diff --git a/modules/lambda-image-public/main.tf b/modules/lambda-image-public/main.tf index 332afad..177a59d 100644 --- a/modules/lambda-image-public/main.tf +++ b/modules/lambda-image-public/main.tf @@ -46,7 +46,7 @@ resource "null_resource" "build_and_push" { } provisioner "local-exec" { - interpreter = ["/bin/sh", "-c"] + interpreter = ["/bin/bash", "-c"] command = <<-EOC set -euo pipefail # Use an ephemeral Docker config to avoid host keychain credential helper conflicts. diff --git a/modules/lambda-image-republish/main.tf b/modules/lambda-image-republish/main.tf index 78d423c..afa0b32 100644 --- a/modules/lambda-image-republish/main.tf +++ b/modules/lambda-image-republish/main.tf @@ -91,7 +91,7 @@ resource "null_resource" "republish_image" { } provisioner "local-exec" { - interpreter = ["/bin/sh", "-c"] + interpreter = ["/bin/bash", "-c"] command = <<-EOC set -euo pipefail # Use an ephemeral Docker config to avoid host keychain credential helper conflicts.