Skip to content

Commit 26ef26a

Browse files
author
thomas loubrieu
committed
validate terraform apply/destroy
1 parent 0e50aad commit 26ef26a

2 files changed

Lines changed: 0 additions & 11 deletions

File tree

terraform/lambda/main.tf

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,20 +22,12 @@ resource "aws_cloudwatch_log_group" "lambda_logs" {
2222
tags = var.common_tags
2323
}
2424

25-
# Create build directory if it doesn't exist
26-
resource "null_resource" "create_build_dir" {
27-
provisioner "local-exec" {
28-
command = "mkdir -p ${path.module}/build"
29-
}
30-
}
31-
3225
resource "null_resource" "build_trigger" {
3326
triggers = {
3427
source_py_hash = filesha256(local.source_file)
3528
build_layer_exists = fileexists("${path.module}/build/${local.lambda_name}.zip") ? "yes" : "no"
3629
}
3730

38-
depends_on = [null_resource.create_build_dir]
3931
}
4032

4133
# Package the lambda source file as a zip
@@ -57,7 +49,6 @@ resource "null_resource" "prepare_layer" {
5749
command = "rm -fr ${path.module}/build/layer/python && mkdir -p ${path.module}/build/layer/ && cp -r ${path.module}/src/layer ${path.module}/build/layer/python && pip install -r ${path.module}/build/layer/python/requirements.txt -t ${path.module}/build/layer/python"
5850
}
5951

60-
depends_on = [null_resource.create_build_dir]
6152
}
6253

6354
# Package the layer as a zip

terraform/main.tf

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,5 +54,3 @@ module "api_gateway" {
5454
aws_region = var.aws_region
5555
common_tags = var.common_tags
5656
}
57-
58-
module "registry-api"

0 commit comments

Comments
 (0)