Commit 2af1c64c by chenxx

update all

1 parent 26aa1d21
...@@ -30,20 +30,19 @@ ...@@ -30,20 +30,19 @@
|------|-------------|------|---------|:--------:| |------|-------------|------|---------|:--------:|
| <a name="input_app_log_path"></a> [app\_log\_path](#input\_app\_log\_path) | @label "应用日志路径" @group "Advanced" | `string` | `"/data/java_log"` | no | | <a name="input_app_log_path"></a> [app\_log\_path](#input\_app\_log\_path) | @label "应用日志路径" @group "Advanced" | `string` | `"/data/java_log"` | no |
| <a name="input_app_log_path_volume_name"></a> [app\_log\_path\_volume\_name](#input\_app\_log\_path\_volume\_name) | 应用日志挂载卷名,名字只能使用-,例: abc-22 abc-cc | `string` | `"app-log-path"` | no | | <a name="input_app_log_path_volume_name"></a> [app\_log\_path\_volume\_name](#input\_app\_log\_path\_volume\_name) | 应用日志挂载卷名,名字只能使用-,例: abc-22 abc-cc | `string` | `"app-log-path"` | no |
| <a name="input_args"></a> [args](#input\_args) | 属于那个环境,例子:dev,test,beta,release | `list(string)` | <pre>[<br> "release"<br>]</pre> | no | | <a name="input_args"></a> [args](#input\_args) | 属于那个环境,例子:dev,test,beta,release | `string` | `"test"` | no |
| <a name="input_domain_name"></a> [domain\_name](#input\_domain\_name) | 域名 | `string` | `""` | no |
| <a name="input_env"></a> [env](#input\_env) | Name and value pairs to set as the environment variables | `map(string)` | `{}` | no | | <a name="input_env"></a> [env](#input\_env) | Name and value pairs to set as the environment variables | `map(string)` | `{}` | no |
| <a name="input_hosts"></a> [hosts](#input\_hosts) | (Optional) host aliases 手动配置域名到hosts | `list(object({ hostname = list(string), ip = string }))` | `[]` | no |
| <a name="input_image"></a> [image](#input\_image) | Docker image name | `string` | n/a | yes | | <a name="input_image"></a> [image](#input\_image) | Docker image name | `string` | n/a | yes |
| <a name="input_limit_cpu"></a> [limit\_cpu](#input\_limit\_cpu) | CPU limit. e.g. 0.5, 1, 2 | `string` | `"0.5"` | no | | <a name="input_ingress_switch"></a> [ingress\_switch](#input\_ingress\_switch) | choise ingress switch | <pre>object({<br> switch = optional(string)<br> path_type = optional(string)<br> path = optional(string)<br> domain_name = optional(string)<br> })</pre> | <pre>{<br> "domain_name": null,<br> "path": "/",<br> "path_type": "ImplementationSpecific",<br> "switch": "off"<br>}</pre> | no |
| <a name="input_limit_memory"></a> [limit\_memory](#input\_limit\_memory) | Memory limit. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi | `string` | `"512Mi"` | no | | <a name="input_limit_cpu"></a> [limit\_cpu](#input\_limit\_cpu) | CPU limit. e.g. 0.5, 1, 2 | `string` | `"1"` | no |
| <a name="input_name"></a> [name](#input\_name) | Name of the deployment resource. Auto-generated if empty. | `string` | `""` | no | | <a name="input_limit_memory"></a> [limit\_memory](#input\_limit\_memory) | Memory limit. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi | `string` | `"1G"` | no |
| <a name="input_namespace"></a> [namespace](#input\_namespace) | Namespace to deploy. Auto-generated if empty. | `string` | `"default"` | no | | <a name="input_name"></a> [name](#input\_name) | Name of the deployment resource. Auto-generated if empty. | `string` | n/a | yes |
| <a name="input_path"></a> [path](#input\_path) | 访问路径 | `string` | `"/"` | no | | <a name="input_namespace"></a> [namespace](#input\_namespace) | Namespace to deploy. Auto-generated if empty. | `string` | n/a | yes |
| <a name="input_path_type"></a> [path\_type](#input\_path\_type) | Path type for ingress rule | `string` | `"ImplementationSpecific"` | no | | <a name="input_ports"></a> [ports](#input\_ports) | Service ports to expose | `list(number)` | <pre>[<br> 6666<br>]</pre> | no |
| <a name="input_ports"></a> [ports](#input\_ports) | Service ports to expose | `list(number)` | n/a | yes |
| <a name="input_replicas"></a> [replicas](#input\_replicas) | Replicas to deploy | `number` | `1` | no | | <a name="input_replicas"></a> [replicas](#input\_replicas) | Replicas to deploy | `number` | `1` | no |
| <a name="input_request_cpu"></a> [request\_cpu](#input\_request\_cpu) | CPU request. e.g. 0.5, 1, 2 | `string` | `"0.1"` | no | | <a name="input_request_cpu"></a> [request\_cpu](#input\_request\_cpu) | CPU request. e.g. 0.5, 1, 2 | `string` | `"0.2"` | no |
| <a name="input_request_memory"></a> [request\_memory](#input\_request\_memory) | Memory request. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi | `string` | `"128Mi"` | no | | <a name="input_request_memory"></a> [request\_memory](#input\_request\_memory) | Memory request. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi | `string` | `"512Mi"` | no |
| <a name="input_restart_policy"></a> [restart\_policy](#input\_restart\_policy) | Restart policy for all containers within the pod. One of Always, OnFailure, Never | `string` | `"Always"` | no | | <a name="input_restart_policy"></a> [restart\_policy](#input\_restart\_policy) | Restart policy for all containers within the pod. One of Always, OnFailure, Never | `string` | `"Always"` | no |
| <a name="input_walrus_metadata_namespace_name"></a> [walrus\_metadata\_namespace\_name](#input\_walrus\_metadata\_namespace\_name) | Walrus metadata namespace name. | `string` | `""` | no | | <a name="input_walrus_metadata_namespace_name"></a> [walrus\_metadata\_namespace\_name](#input\_walrus\_metadata\_namespace\_name) | Walrus metadata namespace name. | `string` | `""` | no |
| <a name="input_walrus_metadata_service_name"></a> [walrus\_metadata\_service\_name](#input\_walrus\_metadata\_service\_name) | Walrus metadata service name. | `string` | `""` | no | | <a name="input_walrus_metadata_service_name"></a> [walrus\_metadata\_service\_name](#input\_walrus\_metadata\_service\_name) | Walrus metadata service name. | `string` | `""` | no |
......
...@@ -25,7 +25,7 @@ module "deployment" { ...@@ -25,7 +25,7 @@ module "deployment" {
image = var.image image = var.image
replicas = var.replicas replicas = var.replicas
restart_policy = var.restart_policy restart_policy = var.restart_policy
args = var.args args = [var.args]
resources = { resources = {
request_cpu = var.request_cpu == "" ? null : var.request_cpu request_cpu = var.request_cpu == "" ? null : var.request_cpu
limit_cpu = var.limit_cpu == "" ? null : var.limit_cpu limit_cpu = var.limit_cpu == "" ? null : var.limit_cpu
...@@ -62,6 +62,13 @@ module "deployment" { ...@@ -62,6 +62,13 @@ module "deployment" {
#affinity: default=true #affinity: default=true
prevent_deploy_on_the_same_node = var.prevent_deploy_on_the_same_node prevent_deploy_on_the_same_node = var.prevent_deploy_on_the_same_node
#RollingUpdate
rolling_update = [
{
"max_surge" = var.max_surge,
"max_unavailable" = var.max_unavailable
}
]
} }
...@@ -86,18 +93,24 @@ module "service" { ...@@ -86,18 +93,24 @@ module "service" {
} }
module "ingress" { module "ingress" {
count = var.ingress_switch.switch == "on" ? 1 : 0
source = "./modules/ingress/kubernetes" source = "./modules/ingress/kubernetes"
ingress_name = local.name ingress_name = local.name
service_namespace = local.namespace service_namespace = local.namespace
service_name = local.name service_name = local.name
annotations = var.annotations # annotations = {
rule = [ # "nginx.ingress.kubernetes.io/proxy-send-timeout" = "360"
# "nginx.ingress.kubernetes.io/proxy-read-timeout" = "360"
# }
annotations = var.ingress_switch.annotations
rule = [
{ {
domain = var.domain_name domain = var.ingress_switch.domain_name
external_port = var.ports[0] // Service port external_port = var.ports[0] // Service port
path = var.path path = var.ingress_switch.path
path_type = var.path_type path_type = var.ingress_switch.path_type
} }
] ]
......
...@@ -195,8 +195,9 @@ variable "rolling_update" { ...@@ -195,8 +195,9 @@ variable "rolling_update" {
variable "wait_for_rollout" { variable "wait_for_rollout" {
default = true default = true
} }
variable "prevent_deploy_on_the_same_node" { variable "prevent_deploy_on_the_same_node" {
description = "Pod pod_anti_affinity rule, which prevents deploy same pod on one node." description = "Pod pod_anti_affinity rule, which prevents deploy same pod on one node."
type = bool type = bool
default = false default = true
} }
\ No newline at end of file \ No newline at end of file
...@@ -2,6 +2,6 @@ terraform { ...@@ -2,6 +2,6 @@ terraform {
required_version = ">= 0.14.8" required_version = ">= 0.14.8"
required_providers { required_providers {
kubernetes = ">= 2.1.0" kubernetes = "2.27.0"
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -10,6 +10,7 @@ resource "kubernetes_ingress_v1" "ingress" { ...@@ -10,6 +10,7 @@ resource "kubernetes_ingress_v1" "ingress" {
ingress_class_name = var.ingress_class_name ingress_class_name = var.ingress_class_name
dynamic "rule" { dynamic "rule" {
for_each = var.rule for_each = var.rule
content { content {
host = "${lookup(rule.value, "sub_domain", "")}${lookup(rule.value, "domain", var.domain_name)}" host = "${lookup(rule.value, "sub_domain", "")}${lookup(rule.value, "domain", var.domain_name)}"
......
...@@ -10,5 +10,5 @@ output "ports" { ...@@ -10,5 +10,5 @@ output "ports" {
output "ingress" { output "ingress" {
description = "访问入口ingress" description = "访问入口ingress"
value = var.domain_name value = try(var.ingress_switch.domain_name, "未配置域名")
} }
...@@ -7,7 +7,8 @@ components: ...@@ -7,7 +7,8 @@ components:
type: object type: object
required: required:
- image - image
- ports - name
- namespace
properties: properties:
image: image:
title: Image title: Image
...@@ -16,16 +17,33 @@ components: ...@@ -16,16 +17,33 @@ components:
x-walrus-ui: x-walrus-ui:
group: Basic group: Basic
order: 1 order: 1
namespace:
title: Namespace
type: string
description: Namespace to deploy. Auto-generated if empty.
x-walrus-ui:
group: Basic
order: 2
name:
title: Name
type: string
description: Name of the deployment resource. Auto-generated if empty.
x-walrus-ui:
group: Basic
order: 3
ports: ports:
title: Ports title: Ports
type: array type: array
description: Service ports to expose description: Service ports to expose
default:
- 6666
items: items:
type: number type: number
nullable: true
x-walrus-ui: x-walrus-ui:
colSpan: 12 colSpan: 12
group: Basic group: Advanced
order: 2 order: 4
env: env:
title: Env title: Env
type: object type: object
...@@ -36,8 +54,8 @@ components: ...@@ -36,8 +54,8 @@ components:
type: string type: string
x-walrus-ui: x-walrus-ui:
colSpan: 12 colSpan: 12
group: Basic group: Advanced
order: 3 order: 5
replicas: replicas:
title: Replicas title: Replicas
type: number type: number
...@@ -45,61 +63,72 @@ components: ...@@ -45,61 +63,72 @@ components:
default: 1 default: 1
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Advanced
order: 4 order: 6
request_cpu: request_cpu:
title: Request Cpu title: Request Cpu
type: string type: string
description: CPU request. e.g. 0.5, 1, 2 description: CPU request. e.g. 0.5, 1, 2
default: "0.1" default: ""
enum:
- 0.2
- 0.3
- 0.4
- 0.5
- 1
- 2
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Resources
order: 5 order: 7
request_memory: request_memory:
title: Request Memory title: Request Memory
type: string type: string
description: Memory request. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi description: Memory request. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi
default: 128Mi default: 512Mi
enum:
- 128Mi
- 512Mi
- 1Gi
- 2Gi
- 3Gi
- 4Gi
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Resources
order: 6 order: 8
limit_cpu: limit_cpu:
title: Limit Cpu title: Limit Cpu
type: string type: string
description: CPU limit. e.g. 0.5, 1, 2 description: CPU limit. e.g. 0.5, 1, 2
default: "0.5" default: ""
enum:
- 0.2
- 0.3
- 0.4
- 0.5
- 1
- 2
- 3
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Resources
order: 7 order: 9
limit_memory: limit_memory:
title: Limit Memory title: Limit Memory
type: string type: string
description: Memory limit. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi description: Memory limit. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi
default: 512Mi default: 1Gi
nullable: true enum:
x-walrus-ui: - 128Mi
group: Basic - 512Mi
order: 8 - 1Gi
namespace: - 2Gi
title: Namespace - 3Gi
type: string - 4Gi
description: Namespace to deploy. Auto-generated if empty.
default: default
nullable: true
x-walrus-ui:
group: Basic
order: 9
name:
title: Name
type: string
description: Name of the deployment resource. Auto-generated if empty.
default: ""
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Resources
order: 10 order: 10
walrus_metadata_service_name: walrus_metadata_service_name:
title: Walrus Metadata Service Name title: Walrus Metadata Service Name
...@@ -109,6 +138,7 @@ components: ...@@ -109,6 +138,7 @@ components:
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Basic
hidden: true
order: 11 order: 11
walrus_metadata_namespace_name: walrus_metadata_namespace_name:
title: Walrus Metadata Namespace Name title: Walrus Metadata Namespace Name
...@@ -118,6 +148,7 @@ components: ...@@ -118,6 +148,7 @@ components:
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Basic
hidden: true
order: 12 order: 12
app_log_path_volume_name: app_log_path_volume_name:
title: App Log Path Volume Name title: App Log Path Volume Name
...@@ -126,7 +157,7 @@ components: ...@@ -126,7 +157,7 @@ components:
default: app-log-path default: app-log-path
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Advanced
order: 13 order: 13
app_log_path: app_log_path:
title: App Log Path title: App Log Path
...@@ -134,7 +165,7 @@ components: ...@@ -134,7 +165,7 @@ components:
default: /data/java_log default: /data/java_log
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Advanced
order: 14 order: 14
restart_policy: restart_policy:
title: Restart Policy title: Restart Policy
...@@ -144,48 +175,96 @@ components: ...@@ -144,48 +175,96 @@ components:
default: Always default: Always
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Advanced
order: 15 order: 15
args: args:
title: Args title: Args
type: array type: string
description: 属于那个环境,例子:dev,test,beta,release description: 属于那个环境,例子:dev,test,beta,release, gh_release, gh_beta, testcdp,
testscrm
default: default:
- test
enum:
- dev
- test
- beta
- release - release
- gh_release
- gh_beta
- testcdp
- testscrm
items: items:
type: string type: string
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
colSpan: 12 colSpan: 12
group: Basic group: Advanced
order: 16 order: 16
domain_name: ingress_switch:
title: Domain Name title: Ingress Switch
type: string type: object
description: 域名 description: choise ingress switch
default: "" default:
annotations: {}
domain_name: null
path: /
path_type: ImplementationSpecific
switch: "off"
nullable: true nullable: true
properties:
annotations:
additionalProperties:
type: object
x-walrus-ui:
colSpan: 12
showIf: switch=on
nullable: true
title: Annotations
type: object
x-walrus-ui:
colSpan: 12
order: 5
showIf: switch=on
domain_name:
nullable: true
title: Domain Name
type: string
x-walrus-ui:
order: 4
showIf: switch=on
path:
default: /
nullable: true
title: Path
type: string
x-walrus-ui:
order: 3
showIf: switch=on
path_type:
default: ImplementationSpecific
enum:
- ImplementationSpecific
- Exact
- Prefix
nullable: true
title: Path Type
type: string
x-walrus-ui:
order: 2
showIf: switch=on
switch:
enum:
- "off"
- "on"
nullable: true
title: Switch
type: string
x-walrus-ui:
order: 1
x-walrus-ui: x-walrus-ui:
group: Basic colSpan: 12
group: Ingress
order: 17 order: 17
path_type:
title: Path Type
type: string
description: Path type for ingress rule
default: ImplementationSpecific
nullable: true
x-walrus-ui:
group: Basic
order: 18
path:
title: Path
type: string
description: 访问路径
default: /
nullable: true
x-walrus-ui:
group: Basic
order: 19
hosts: hosts:
title: Hosts title: Hosts
type: array type: array
...@@ -215,17 +294,8 @@ components: ...@@ -215,17 +294,8 @@ components:
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
colSpan: 12 colSpan: 12
group: Basic group: Advanced
order: 20 order: 18
annotations:
title: Annotations
type: object
description: (Optional) Custom Annotations
nullable: true
x-walrus-ui:
colSpan: 12
group: Basic
order: 21
prevent_deploy_on_the_same_node: prevent_deploy_on_the_same_node:
title: Prevent Deploy On The Same Node title: Prevent Deploy On The Same Node
type: boolean type: boolean
...@@ -234,8 +304,31 @@ components: ...@@ -234,8 +304,31 @@ components:
default: true default: true
nullable: true nullable: true
x-walrus-ui: x-walrus-ui:
group: Basic group: Advanced
order: 20
max_surge:
title: Max Surge
type: number
description: Rolling update config params. Present only if strategy_update
= RollingUpdate max_surge
default: 1
nullable: true
x-walrus-ui:
group: Advanced
order: 21
max_unavailable:
title: Max Unavailable
type: number
description: Rolling update config params. Present only if strategy_update
= RollingUpdate max_unavailable
default: 0
nullable: true
x-walrus-ui:
group: Advanced
order: 22 order: 22
x-walrus-ui: x-walrus-ui:
groupOrder: groupOrder:
- Basic - Basic
- Resourced
- Advanced
- Ingress
...@@ -4,11 +4,27 @@ variable "image" { ...@@ -4,11 +4,27 @@ variable "image" {
type = string type = string
description = "Docker image name" description = "Docker image name"
} }
# @label "Namespace"
# @group "Basic"
variable "namespace" {
type = string
description = "Namespace to deploy. Auto-generated if empty."
}
# @label "Deployment Name"
# @group "Advanced"
variable "name" {
type = string
description = "Name of the deployment resource. Auto-generated if empty."
}
# @label "Ports" # @label "Ports"
# @group "Basic" # @group "Basic"
variable "ports" { variable "ports" {
type = list(number) type = list(number)
description = "Service ports to expose" description = "Service ports to expose"
default = [6666]
} }
# @label "Environment Variables" # @label "Environment Variables"
# @options ["dev", "test", "release", "beta"] # @options ["dev", "test", "release", "beta"]
...@@ -31,7 +47,7 @@ variable "replicas" { ...@@ -31,7 +47,7 @@ variable "replicas" {
variable "request_cpu" { variable "request_cpu" {
type = string type = string
description = "CPU request. e.g. 0.5, 1, 2" description = "CPU request. e.g. 0.5, 1, 2"
default = "0.1" default = ""
} }
# @group "Resources" # @group "Resources"
# @options ["128Mi","512Mi", "1G"] # @options ["128Mi","512Mi", "1G"]
...@@ -39,7 +55,7 @@ variable "request_cpu" { ...@@ -39,7 +55,7 @@ variable "request_cpu" {
variable "request_memory" { variable "request_memory" {
type = string type = string
description = "Memory request. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi" description = "Memory request. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi"
default = "128Mi" default = "512Mi"
} }
# @group "Resources" # @group "Resources"
# @options ["0.2","0.3", "0.5","1", "2"] # @options ["0.2","0.3", "0.5","1", "2"]
...@@ -47,7 +63,7 @@ variable "request_memory" { ...@@ -47,7 +63,7 @@ variable "request_memory" {
variable "limit_cpu" { variable "limit_cpu" {
type = string type = string
description = "CPU limit. e.g. 0.5, 1, 2" description = "CPU limit. e.g. 0.5, 1, 2"
default = "0.5" default = ""
} }
# @group "Resources" # @group "Resources"
# @options ["128Mi","512Mi", "1Gi","2Gi", "3Gi"] # @options ["128Mi","512Mi", "1Gi","2Gi", "3Gi"]
...@@ -55,22 +71,10 @@ variable "limit_cpu" { ...@@ -55,22 +71,10 @@ variable "limit_cpu" {
variable "limit_memory" { variable "limit_memory" {
type = string type = string
description = "Memory limit. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi" description = "Memory limit. e.g. 128Mi, 512Mi, 1Gi, 2Gi, 4Gi"
default = "512Mi" default = "1G"
}
# @label "Namespace"
# @group "Advanced"
variable "namespace" {
type = string
description = "Namespace to deploy. Auto-generated if empty."
default = "default"
}
# @label "Deployment Name"
# @group "Advanced"
variable "name" {
type = string
description = "Name of the deployment resource. Auto-generated if empty."
default = ""
} }
# @hidden # @hidden
variable "walrus_metadata_service_name" { variable "walrus_metadata_service_name" {
type = string type = string
...@@ -113,54 +117,58 @@ variable "restart_policy" { ...@@ -113,54 +117,58 @@ variable "restart_policy" {
# @options ["dev", "test", "beta", "release"] # @options ["dev", "test", "beta", "release"]
# @group "Advanced" # @group "Advanced"
variable "args" { variable "args" {
type = list(string) type = string
description = "属于那个环境,例子:dev,test,beta,release" description = "属于那个环境,例子:dev,test,beta,release"
default = ["release"] default = "test"
} }
# @label "域名名字" # @label "chiose ingress switch on or off"
# @group "ingress" # @options ["on", "off"]
variable "domain_name" { # @group "Ingress"
type = string variable "ingress_switch" {
description = "域名" type = object({
default = "" switch = optional(string)
path_type = optional(string)
path = optional(string)
domain_name = optional(string)
annotations = optional(map(any))
})
default = {
switch = "off"
path_type = "ImplementationSpecific"
path = "/"
domain_name = null
annotations = {}
}
description = "choise ingress switch"
} }
# @label "path_type" # @label "host aliases 手动配置域名到hosts"
# @options ["ImplementationSpecific","Exact","Prefix"] # @group "Advanced"
# @group "ingress"
variable "path_type" {
type = string
description = "Path type for ingress rule"
default = "ImplementationSpecific"
}
# @label "path"
# @group "ingress"
variable "path" {
type = string
description = "访问路径"
default = "/"
}
# @label "path"
# @group "advance"
variable "hosts" { variable "hosts" {
type = list(object({ hostname = list(string), ip = string })) type = list(object({ hostname = list(string), ip = string }))
description = "(Optional) Add /etc/hosts records to pods" description = "(Optional) host aliases 手动配置域名到hosts"
default = [] default = []
} }
# @label "annotations"
# @group "advance"
variable "annotations" {
description = "(Optional) Custom Annotations"
default = null
}
# @label "affinity" # @label "affinity"
# @group "advance" # @group "advance"
variable "prevent_deploy_on_the_same_node" { variable "prevent_deploy_on_the_same_node" {
description = "Pod pod_anti_affinity rule, which prevents deploy same pod on one node." description = "Pod pod_anti_affinity rule, which prevents deploy same pod on one node."
type = bool type = bool
default = true default = false
}
# @label "max_surge"
# @group "advance"
variable "max_surge" {
description = "Rolling update config params. Present only if strategy_update = RollingUpdate max_surge"
default = 1
} }
# @label "max_unavailable"
# @group "advance"
variable "max_unavailable" {
description = "Rolling update config params. Present only if strategy_update = RollingUpdate max_unavailable"
default = 0
}
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!