Skip to content

Commit db0be01

Browse files
committed
fix paths
1 parent 09dae53 commit db0be01

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

terraform/modules/run-service/docker.tf

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
# Calculate hash of source files to determine if rebuild is needed
22
locals {
3-
source_files = fileset(path.root, "../${var.function_name}/*")
3+
source_files = fileset(path.root, "${var.source_directory}/*")
44
source_hash = substr(sha1(join("", [for f in local.source_files : filesha1(f)])), 0, 8)
55
}
66

77
# Build Docker image
88
resource "docker_image" "function_image" {
9-
name = "${var.region}-docker.pkg.dev/${var.project}/dataform/${var.function_name}:${local.source_hash}"
9+
name = "${var.region}-docker.pkg.dev/${var.project}/cloud-run/${var.function_name}:${local.source_hash}"
1010

1111
build {
12-
context = "../${var.function_name}/"
12+
context = var.source_directory
1313
dockerfile = "Dockerfile"
1414
platform = "linux/amd64"
1515
}

0 commit comments

Comments
 (0)