Yaml
Yaml 是用于将对象定义保存为 YAML 格式的输入。
💡 常见的 yaml Usage
yaml 输入类型可被用来存储任何基于键/值的数据,例如
- 配置;
- Helm 图表;
- 字典/哈希图
- 配置清单;
values.yml
;- 等。
应用程序接口定义
- Basic
- Array
{
"myYamlInput": {
"title": "My yaml input",
"icon": "My icon",
"description": "My yaml input",
"type": "string",
"format": "yaml"
}
}
{
"myYamlArrayInput": {
"title": "My yaml array input",
"icon": "My icon",
"description": "My yaml array input",
"type": "array",
"items": {
"type": "string",
"format": "yaml"
}
}
}
Check out Port's API reference to learn more.
Terraform 定义
- Basic
- Array
resource "port_action" "myAction" {
# ...action properties
user_properties = {
string_props = {
"myYamlInput" = {
title = "My yaml input"
description = "My yaml input"
}
}
}
}
resource "port_action" "myAction" {
# ...action properties
user_properties = {
array_props = {
"myYamlArrayInput" = {
title = "My yaml array input"
description = "My yaml array input"
string_items = {
format = "yaml"
}
}
}
}
}