Skip to content

Commit 2bbf150

Browse files
committed
Add missing app configuration
1 parent 6cb1584 commit 2bbf150

File tree

3 files changed

+19
-0
lines changed

3 files changed

+19
-0
lines changed

code/infra/function.tf

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,10 @@ resource "azapi_resource" "function" {
117117
name = "DOCKER_SHM_SIZE"
118118
value = "268435456"
119119
},
120+
{
121+
name = "DOCKER_REGISTRY_SERVER_URL"
122+
value = var.function_container_registry_url
123+
},
120124
{
121125
name = "PYTHON_THREADPOOL_THREAD_COUNT"
122126
value = "None"
@@ -133,6 +137,10 @@ resource "azapi_resource" "function" {
133137
name = "WEBSITE_RUN_FROM_PACKAGE"
134138
value = "0"
135139
},
140+
{
141+
name = "WEBSITES_ENABLE_APP_SERVICE_STORAGE"
142+
value = "false"
143+
},
136144
{
137145
name = "PYTHON_ENABLE_WORKER_EXTENSIONS"
138146
value = "1"

code/infra/variables.tf

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,16 @@ variable "tags" {
3434
}
3535

3636
# Function variables
37+
variable "function_container_registry_url" {
38+
description = "Specifies the container image reference of the Azure Function."
39+
type = string
40+
sensitive = false
41+
validation {
42+
condition = startswith(var.function_container_registry_url, "https://")
43+
error_message = "Please specify a valid container image reference."
44+
}
45+
}
46+
3747
variable "function_container_image" {
3848
description = "Specifies the container image reference of the Azure Function."
3949
type = string

config/PerfectThymeTech/vars.tfvars

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ prefix = "myfunc"
55
tags = {}
66

77
# Function variables
8+
function_container_registry_url = "https://ghcr.io"
89
function_container_image = "ghcr.io/perfectthymetech/azurefunctionpython:main"
910
function_sku = "P0v3"
1011
function_sku_cpus = 1

0 commit comments

Comments
 (0)