Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 54 additions & 13 deletions azure/specs/service-spec.json.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"fixed_instances",
"scheduled_stop",
"additional_ports",
"protocol",
"continuous_delivery"
],
"uiSchema":{
Expand Down Expand Up @@ -101,10 +102,6 @@
"type":"Control",
"scope":"#/properties/autoscaling/properties/target_cpu_utilization"
},
{
"type": "Control",
"scope": "#/properties/autoscaling/properties/target_memory_enabled"
},
{
"rule": {
"effect": "SHOW",
Expand Down Expand Up @@ -170,6 +167,19 @@
}
]
},
{
"type": "Category",
"label": "Protocol",
"elements": [
{
"type": "Control",
"scope": "#/properties/protocol",
"options": {
"format": "radio"
}
}
]
},
{
"type":"Category",
"label":"Continuous deployment",
Expand Down Expand Up @@ -382,17 +392,17 @@
"description":"CPU utilization threshold that triggers scaling"
},
"target_memory_enabled": {
"type": "boolean",
"title": "Scale by memory",
"default": false
"type": "boolean",
"title": "Scale by memory",
"default": false
},
"target_memory_utilization": {
"type": "integer",
"title": "Target memory utilization (%)",
"default": 70,
"maximum": 90,
"minimum": 30,
"description": "Memory utilization threshold that triggers scaling"
"type": "integer",
"title": "Target memory utilization (%)",
"default": 70,
"maximum": 90,
"minimum": 50,
"description": "Memory utilization threshold that triggers scaling"
}
}
},
Expand Down Expand Up @@ -539,6 +549,7 @@
],
"type":"string",
"title":"Port Type",
"default": "GRPC",
"description":"The protocol type for this port"
}
}
Expand Down Expand Up @@ -576,6 +587,36 @@
}
},
"description":"Configure automatic deployment from Git branches"
},
"custom_domains": {
"type": "object",
"required": [
"enabled"
],
"properties": {
"enabled": {
"type": "boolean",
"default": true
}
}
},
"protocol": {
"type": "string",
"oneOf": [
{
"const": "http",
"title": "HTTP connections",
"description": "Enable http web server"
},
{
"const": "web_sockets",
"title": "Web sockets",
"description": "Enable web sockets connections"
}
],
"title": "Protocol",
"default": "http",
"description": "Define the inbound traffic the application will accept"
}
}
}
Expand Down
10 changes: 9 additions & 1 deletion k8s/deployment/build_context
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,15 @@ fi
IMAGE_PULL_SECRETS="${IMAGE_PULL_SECRETS:-"{}"}"
IMAGE_PULL_SECRETS=$(echo "$IMAGE_PULL_SECRETS" | jq .)

TRAFFIC_CONTAINER_IMAGE=${TRAFFIC_CONTAINER_IMAGE:-"public.ecr.aws/nullplatform/k8s-traffic-manager:latest"}
SCOPE_TRAFFIC_PROTOCOL=$(echo "$CONTEXT" | jq -r .scope.capabilities.protocol)

TRAFFIC_CONTAINER_VERSION="latest"

if [[ "$SCOPE_TRAFFIC_PROTOCOL" == "web_sockets" ]]; then
TRAFFIC_CONTAINER_VERSION="websocket2"
fi

TRAFFIC_CONTAINER_IMAGE=${TRAFFIC_CONTAINER_IMAGE:-"public.ecr.aws/nullplatform/k8s-traffic-manager:$TRAFFIC_CONTAINER_VERSION"}

# Pod Disruption Budget configuration
PDB_ENABLED=${POD_DISRUPTION_BUDGET_ENABLED:-"false"}
Expand Down
33 changes: 33 additions & 0 deletions k8s/specs/service-spec.json.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"fixed_instances",
"scheduled_stop",
"additional_ports",
"protocol",
"continuous_delivery"
],
"uiSchema":{
Expand Down Expand Up @@ -166,6 +167,19 @@
}
]
},
{
"type": "Category",
"label": "Protocol",
"elements": [
{
"type": "Control",
"scope": "#/properties/protocol",
"options": {
"format": "radio"
}
}
]
},
{
"type":"Category",
"label":"Continuous deployment",
Expand Down Expand Up @@ -535,6 +549,7 @@
],
"type":"string",
"title":"Port Type",
"default": "GRPC",
"description":"The protocol type for this port"
}
}
Expand Down Expand Up @@ -584,6 +599,24 @@
"default": true
}
}
},
"protocol": {
"type": "string",
"oneOf": [
{
"const": "http",
"title": "HTTP connections",
"description": "Enable http web server"
},
{
"const": "web_sockets",
"title": "Web sockets",
"description": "Enable web sockets connections"
}
],
"title": "Protocol",
"default": "http",
"description": "Define the inbound traffic the application will accept"
}
}
}
Expand Down