-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
control-service: Make fluentdconfig configurable #74
control-service: Make fluentdconfig configurable #74
Conversation
1d9767a
to
742e576
Compare
projects/control-service/projects/helm_charts/pipelines-control-service/Chart.lock
Outdated
Show resolved
Hide resolved
.../control-service/projects/helm_charts/pipelines-control-service/templates/fluentdconfig.yaml
Outdated
Show resolved
Hide resolved
.../control-service/projects/helm_charts/pipelines-control-service/templates/fluentdconfig.yaml
Show resolved
Hide resolved
.../control-service/projects/helm_charts/pipelines-control-service/templates/fluentdconfig.yaml
Show resolved
Hide resolved
projects/control-service/projects/helm_charts/pipelines-control-service/values.yaml
Show resolved
Hide resolved
4e0e21e
to
080b655
Compare
Please avoid said in testing done "local", "manual", those do not really tell anything to the reader. Reminder from the git template |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything looks good to me. I want to review how it was tested only. How we are sure the produced config is valid and working.
This change allows the fluentdconfig to be altered through the Values.yml file. The purpose of this is that making changes to a deployed version of control-service no long requires pushing changes to the main control-service repository. The fluentd block in values.yml includes three values relevant to the config - filter, match and extra. Filter and match are inserted into the corresponding filter and match blocks in the fluentdconfig, whereas extra is any additional configuration you might include using the remaining directives. Testing done: With the following config in Values.yml: ```yml fluentd: enabled: true filter: |- @type parser key_name log reserve_data true remove_key_name_field true <parse> @type json </parse> match: |- @type elastic ``` We get the following config: ```yml apiVersion: logs.vdp.vmware.com/v1beta1 kind: FluentdConfig metadata: name: pipelines-control-service-parser spec: fluentconf: | <filter $labels(app_kubernetes_io/name=pipelines-control-service)> @type parser key_name log reserve_data true remove_key_name_field true <parse> @type json </parse> </filter> <match $labels(app_kubernetes_io/name=pipelines-control-service)> @type elastic </match> ``` If we extend the config the with a fluentd.extra value: ```yml extra: |- <source> @type http port 8090 </source> <system> some system config </system> ``` We get the following fluentdconfig: ```yml apiVersion: logs.vdp.vmware.com/v1beta1 kind: FluentdConfig metadata: name: pipelines-control-service-parser spec: fluentconf: | <source> @type http port 8090 </source> <system> some system config </system> <filter $labels(app_kubernetes_io/name=pipelines-control-service)> @type parser key_name log reserve_data true remove_key_name_field true <parse> @type json </parse> </filter> <match $labels(app_kubernetes_io/name=pipelines-control-service)> @type elastic </match> ``` Signed-off-by: gageorgiev <[email protected]>
080b655
to
899e46b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. Looks good to me.
This change allows the fluentdconfig to be altered
through the Values.yml file. The purpose of this is
that making changes to a deployed version of
control-service no long requires pushing changes to
the main control-service repository.
Testing done:
With the following config in Values.yml:
We get the following config:
If we extend the config the with a fluentd.extra value:
We get the following fluentdconfig:
Signed-off-by: gageorgiev [email protected]