Skip to content

Commit c2439a6

Browse files
committed
error out when we fail at local-exec
1 parent ce0ea43 commit c2439a6

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

terraform/resources/ecr.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ resource null_resource ecr_image {
1818

1919
provisioner "local-exec" {
2020
command = <<EOF
21+
set -e
2122
aws ecr get-login-password --region ${data.aws_region.current.name} | docker login --username AWS --password-stdin "https://${data.aws_caller_identity.current.account_id}.dkr.ecr.${data.aws_region.current.name}.amazonaws.com"
2223
if [ "${var.arch}" = "arm64" ]; then
2324
LAMBDA_IMAGE="amazon/aws-lambda-provided:al2023.2024.05.01.10"

0 commit comments

Comments
 (0)