-
Notifications
You must be signed in to change notification settings - Fork 1.9k
[logstash] first version of logstash helm chart #333
Conversation
59228fc
to
fa28783
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 for working on this! I added some comments on a brief review. I'll also compare this with what we have deployed in Infosec for this later.
podManagementPolicy: "Parallel" | ||
|
||
protocol: http | ||
httpPort: 9600 |
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.
I don't recommend exposing Logstash's http API as it is, to my knowledge, unauthenticated and has an API for mutation of things like log level.
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.
readinessProbe: | ||
httpGet: | ||
path: / | ||
port: http |
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.
readiness is complicated. A successful HTTP call to port 9600 doesn't necessarily mean Logstash is capable of serving business needs.
I don't have any alternative solutions in mind, but I'll try to think of something. In the meantime, this comment is not a blocker ;)
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.
Yes I guess I'll start like that and we'll see how we can set a better probe in a second time.
58ff841
to
39f9723
Compare
Chart Tests are not relevant for Logstash as we don't use service while chart tests usually imply running another pod which request some service resource. |
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.
This is looking great! I didn't try to run it or play around with it yet but it is shaping up very nicely!
The main thing missing functionality wise right now is how to handle services and ingress. This is a bit trickier for logstash since it is normal for a logstash instance to have multiple or none service endpoints.
|
||
# A list of secrets and their paths to mount inside the pod | ||
secretMounts: [] | ||
|
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.
I think leaving in the commented example like the Elasticsearch chart would make it easier for users to know the formatting.
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.
Yeah for this one I'd like to add a commented example. Do you have any good use case needing a secret mount in Logstash so we can have a relevant example.
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.
Best example would be for mounting certificates to be able to talk to Elasticsearch with security enabled.
|
||
logstashJavaOpts: "-Xmx1g -Xms1g" | ||
|
||
resources: |
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.
I think these are just copied for Elasticsearch for now. But we should chat with the Logstash team (or check docs) to see what the recommended defaults would be.
68a85c0
to
92130a8
Compare
I guess this is ready for a second review and hope to be able to merge it and add the missing parts in following PR. Status of what's not fully completed in this PR:
|
Logstash HTTP API shouldn't be exposed externally as Logstash doesn't manage any authentication on this API. Also as Logstash doesn't support clustering, being able to access this API via a service doesn't make sense.
`release` label need to be added StatefulSet `spec.selector.matchLabels` to be included in pvc so we can select only pvc matching release
…ipeline configmap has changed
92130a8
to
85c657b
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.
LGTM! This is amazing work :) 🌟
I didn't find any recommendation for default values in Logstash documentation. I guess we can add them in a following PR.
Yup, I do think it would be a good idea to get these set properly before the first release though so that we can still change them.
Need to test Beats input
I don't think we really need to do this. For something like Kibana it makes sense to check that it can connect to Elasticsearch because it is required. I think that as long as we make sure that Logstash has the capability to talk to an output with certificates/passwords that it should be enough. So just making sure that secrets can be mounted, passwords can be passed into the config via the environment variable should mean that all outputs will be supported. Testing all of the output plugins would be a bit unreasonable and is something best left to the Logstash team.
Need to add service and ingress for logstash inputs
Service has been added in 68a85c0, I'm not sure if we really want to manage Ingress for the "listener inputs". I guess if we need that we can add it in a following PR.
+1 On adding ingress, with the ability to create an ingress per service input in Logstash. But yeah that can totally wait for another PR.
@@ -0,0 +1,39 @@ | |||
--- |
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.
If you want you could split these jobs off into a separate PR. That way we can have Jenkins running CI tests for the changes in here.
|
||
# A list of secrets and their paths to mount inside the pod | ||
secretMounts: [] | ||
|
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.
Best example would be for mounting certificates to be able to talk to Elasticsearch with security enabled.
# annotations: {} | ||
# type: ClusterIP | ||
# ports: | ||
# - name: beats |
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.
Nice! It's really cool that you can just support multiple ports and types this way.
can't see this on the repo yet
wanted to give it a try, thanks! |
Hi @masterkain, Logtsash chart hasn't been uploaded to Elastic Helm repository yet. It should be released soon on Helm repos with 7.5.0 release. In the meantime, you need to install it from GitHub repo:
|
This is the first version of logstash helm chart.
Related to #69
TODO
&templates/tests
NOTES.txt
and ingress for logstash inputs