diff options
-rw-r--r-- | roles/openshift_logging_fluentd/templates/fluentd.j2 | 10 | ||||
-rw-r--r-- | roles/openshift_logging_mux/templates/mux.j2 | 10 |
2 files changed, 16 insertions, 4 deletions
diff --git a/roles/openshift_logging_fluentd/templates/fluentd.j2 b/roles/openshift_logging_fluentd/templates/fluentd.j2 index a5695ee26..d9814370f 100644 --- a/roles/openshift_logging_fluentd/templates/fluentd.j2 +++ b/roles/openshift_logging_fluentd/templates/fluentd.j2 @@ -98,9 +98,15 @@ spec: - name: "BUFFER_SIZE_LIMIT" value: "{{ openshift_logging_fluentd_buffer_size_limit }}" - name: "FLUENTD_CPU_LIMIT" - value: "{{ openshift_logging_fluentd_cpu_limit }}" + valueFrom: + resourceFieldRef: + containerName: "{{ daemonset_container_name }}" + resource: limits.cpu - name: "FLUENTD_MEMORY_LIMIT" - value: "{{ openshift_logging_fluentd_memory_limit }}" + valueFrom: + resourceFieldRef: + containerName: "{{ daemonset_container_name }}" + resource: limits.memory volumes: - name: runlogjournal hostPath: diff --git a/roles/openshift_logging_mux/templates/mux.j2 b/roles/openshift_logging_mux/templates/mux.j2 index 243698c6a..1f991d434 100644 --- a/roles/openshift_logging_mux/templates/mux.j2 +++ b/roles/openshift_logging_mux/templates/mux.j2 @@ -108,9 +108,15 @@ spec: - name: "BUFFER_SIZE_LIMIT" value: "{{ openshift_logging_mux_buffer_size_limit }}" - name: "MUX_CPU_LIMIT" - value: "{{ openshift_logging_mux_cpu_limit }}" + valueFrom: + resourceFieldRef: + containerName: "mux" + resource: limits.cpu - name: "MUX_MEMORY_LIMIT" - value: "{{ openshift_logging_mux_memory_limit }}" + valueFrom: + resourceFieldRef: + containerName: "mux" + resource: limits.memory volumes: - name: config configMap: |