Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
terraform_module
/
standard_webservice
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 46bc1a76
authored
Oct 26, 2023
by
chenxx
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
update README.md and add args
1 parent
5f86a315
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
0 deletions
README.md
main.tf
variables.tf
README.md
View file @
46bc1a7
...
@@ -29,6 +29,7 @@
...
@@ -29,6 +29,7 @@
|------|-------------|------|---------|:--------:|
|------|-------------|------|---------|:--------:|
|
<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
)
| (Optional) Arguments to the entrypoint |
`list(string)`
|
<pre>
[
<br> "release"<br>
]
</pre>
| 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_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`
|
`""`
| no |
|
<a
name=
"input_limit_cpu"
></a>
[
limit\_cpu
](
#input\_limit\_cpu
)
| CPU limit. e.g. 0.5, 1, 2 |
`string`
|
`""`
| no |
...
...
main.tf
View file @
46bc1a7
...
@@ -25,6 +25,7 @@ module "deployment" {
...
@@ -25,6 +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
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
...
...
variables.tf
View file @
46bc1a7
...
@@ -112,3 +112,11 @@ variable "restart_policy" {
...
@@ -112,3 +112,11 @@ variable "restart_policy" {
description = "Restart policy for all containers within the pod. One of Always, OnFailure, Never"
description = "Restart policy for all containers within the pod. One of Always, OnFailure, Never"
default = "Always"
default = "Always"
}
}
# @label "diamond配置环境变量参数"
# @group "Advanced"
variable "args" {
type = list(string)
description = "(Optional) Arguments to the entrypoint"
default = ["release"]
}
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment