Skip to content
Draft
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
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ No modules.
| <a name="input_logs_agent_tolerations"></a> [logs\_agent\_tolerations](#input\_logs\_agent\_tolerations) | List of tolerations to apply to Logs agent. The default value means a pod will run on every node. | <pre>list(object({<br/> key = optional(string)<br/> operator = optional(string)<br/> value = optional(string)<br/> effect = optional(string)<br/> tolerationSeconds = optional(number)<br/> }))</pre> | <pre>[<br/> {<br/> "operator": "Exists"<br/> }<br/>]</pre> | no |
| <a name="input_logs_agent_trusted_profile_id"></a> [logs\_agent\_trusted\_profile\_id](#input\_logs\_agent\_trusted\_profile\_id) | The IBM Cloud trusted profile ID. Used only when `logs_agent_iam_mode` is set to `TrustedProfile`. The trusted profile must have an IBM Cloud Logs `Sender` role. | `string` | `null` | no |
| <a name="input_max_unavailable"></a> [max\_unavailable](#input\_max\_unavailable) | The maximum number of pods that can be unavailable during a DaemonSet rolling update. Accepts absolute number or percentage (e.g., '1' or '10%'). | `string` | `"1"` | no |
| <a name="input_storage_name"></a> [storage\_name](#input\_storage\_name) | The custom name for the fluent cache that stores data streams and chunks, as well as the database file that tracks processed files and their states, helping prevent multiple logs-agents from using the same cache and database. | `string` | `""` | no |
| <a name="input_wait_till"></a> [wait\_till](#input\_wait\_till) | To avoid long wait times when you run your Terraform code, you can specify the stage when you want Terraform to mark the cluster resource creation as completed. Depending on what stage you choose, the cluster creation might not be fully completed and continues to run in the background. However, your Terraform code can continue to run without waiting for the cluster to be fully created. Supported args are `MasterNodeReady`, `OneWorkerNodeReady`, `IngressReady` and `Normal` | `string` | `"Normal"` | no |
| <a name="input_wait_till_timeout"></a> [wait\_till\_timeout](#input\_wait\_till\_timeout) | Timeout for wait\_till in minutes. | `number` | `90` | no |

Expand Down
3 changes: 3 additions & 0 deletions ibm_catalog.json
Original file line number Diff line number Diff line change
Expand Up @@ -471,6 +471,9 @@
{
"key": "wait_till_timeout"
},
{
"key": "storage_name"
},
{
"key": "enable_multiline"
},
Expand Down
5 changes: 5 additions & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ locals {
logs_agent_iam_api_key = var.logs_agent_iam_api_key != null ? var.logs_agent_iam_api_key : ""
logs_agent_trusted_profile_id = var.logs_agent_trusted_profile_id != null ? var.logs_agent_trusted_profile_id : ""
cloud_logs_ingress_endpoint = var.cloud_logs_ingress_endpoint != null ? var.cloud_logs_ingress_endpoint : ""
storage_name = var.storage_name != null ? var.storage_name : ""
logs_agent_additional_metadata = length(var.logs_agent_additional_metadata) > 0 ? merge([
for metadata in var.logs_agent_additional_metadata : {
(metadata.key) = metadata.value
Expand Down Expand Up @@ -131,6 +132,10 @@ resource "helm_release" "logs_agent" {
{
name = "updateStrategy.maxUnavailable"
value = var.max_unavailable
},
{
name = "storageName"
value = local.storage_name
}
]

Expand Down
1 change: 1 addition & 0 deletions solutions/fully-configurable/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -87,5 +87,6 @@ module "logs_agent" {
enable_annotations = var.enable_annotations
log_filters = var.log_filters
max_unavailable = var.max_unavailable
storage_name = var.storage_name
logs_agent_multi_process_workers = var.logs_agent_multi_process_workers
}
7 changes: 7 additions & 0 deletions solutions/fully-configurable/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,13 @@ variable "max_unavailable" {
nullable = false
}

variable "storage_name" {
type = string
description = "The custom name for the fluent cache that stores data streams and chunks, as well as the database file that tracks processed files and their states, helping prevent multiple logs-agents from using the same cache and database."
default = ""
nullable = false
}

variable "provider_visibility" {
description = "Set the visibility value for the IBM terraform provider. Supported values are `public`, `private`, `public-and-private`. [Learn more](https://registry.terraform.io/providers/IBM-Cloud/ibm/latest/docs/guides/custom-service-endpoints)."
type = string
Expand Down
8 changes: 7 additions & 1 deletion variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,6 @@ variable "max_unavailable" {
}
}


variable "log_filters" {

# variable type is any because filters schema is not fixed and there are many filters each having its unique fields.
Expand All @@ -289,3 +288,10 @@ variable "log_filters" {
type = any
default = []
}

variable "storage_name" {
type = string
description = "The custom name for the fluent cache that stores data streams and chunks, as well as the database file that tracks processed files and their states, helping prevent multiple logs-agents from using the same cache and database."
default = ""
nullable = false
}