-
Notifications
You must be signed in to change notification settings - Fork 291
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
[stable/locust] Add support for git sync #641
base: master
Are you sure you want to change the base?
Conversation
Sorry @AlexisBRENON but this is a huge increase in complexity, with no description of why and no docs for how a chart user might make use of this feature. |
How about a more generic approach that moves all this complexity to the values provided to the chart (and hence the person wanting to do this):
This would be very simple and also, AFAIU, would allow you to achieve the same thing? |
Thanks for the feedback. I agree, I didn't take time to document the new features, maybe I opened the PR a little bit early (moreover, the template is not rendering for the moment...). Using a more generic approach report the complexity on the user of the chart. Moreover, it also requires a For information, I took inspiration from the Apache Airflow chart which can also relies on Git Sync to provide DAG files to the different components. Are you totally againt such solution (in which case I can close the PR) or would you let me improve it a little bit (at least adding the documentation) (in which case I will ping you back when it's done) ? Or I can close the current PR and open a new one when I'm ready. |
I'm on holiday right now, I'll revisit it when I get back in Jan, but in principle if there's a bunch of people that want this feature then all good, of course we can fix the issues and merge. But it looks like quite an advanced use case and from what I've seen so far, from the locust repo issues and the locust Slack org, even just using the helm chart as it is now can be a challenge. If anyone else has strong opinions on this then feel free to chime in 😃 Happy holidays @AlexisBRENON 🎄 |
This PR is stale because it has been open 14 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
b44d44e
to
d228d9c
Compare
Hi. I fixed the rendering issue and tried to add more documentation. There is still some stuffs that I copied from the Airflow chart, without exactly knowing what it is used for (lifecycle hooks and security context). I could drop them if you want to keep the code more smaller, but I suspect that it may be of use for certain kind of deployment. Finally, the refactor to allow different images between master and worker may be in another PR, what do you think ? But in this case, where should I put the git Sync image configuration (in As said before, I tried to do a non-breaking change. So a working release should still work with the same values (the images are fetched from the old |
images: | ||
# images.defaultLocustRepository -- default image used by locust containers (master and workers) | ||
defaultLocustRepository: locustio/locust | ||
# images.defaultLocustTag -- default tag used by locust containers (master and workers) | ||
defaultLocustTag: 2.32.2 | ||
|
||
master: | ||
# images.master.repository -- image used by locust master container | ||
repository: ~ | ||
# images.master.tag -- tag used by locust master container | ||
tag: ~ | ||
pullPolicy: IfNotPresent | ||
|
||
worker: | ||
# images.worker.repository -- image used by locust worker containers | ||
repository: ~ | ||
# images.worker.tag -- tag used by locust worker containers | ||
tag: ~ | ||
pullPolicy: IfNotPresent | ||
|
||
gitSync: | ||
# images.gitSync.repository -- image used by gitSync container | ||
repository: registry.k8s.io/git-sync/git-sync | ||
# images.gitSync.tag -- tag used by gitSync container | ||
tag: v4.1.0 | ||
pullPolicy: IfNotPresent | ||
|
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.
Why do we need all this complexity about images? Is it related to git sync?
mountPath: "/mnt/locust" | ||
# locustfiles.requirements -- Path to a file containing requirements to install | ||
requirements: ~ | ||
gitSync: |
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 you can simply remove a lot of they keys in here to make it simpler, e.g. containerName, uid, securityContext, securityContexts, containerLifecycleHooks, extraVolumeMounts etc.
Do we really need to set all these just to get git-sync working? I would say just leave all these as k8s defaults if not
@@ -45,11 +45,18 @@ spec: | |||
{{- if .Values.hostAliases }} | |||
hostAliases: {{- .Values.hostAliases | toYaml | nindent 8 }} | |||
{{- end }} | |||
initContainers: | |||
{{- if .Values.locustfiles.gitSync.enabled }} |
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.
Does this not leave a key with no value if gitSync is not enabled?
It remains way too complicated IMO. I would say either make it much simpler or just create a separate chart, e.g. |
Yeah now I think about it, let's do it as a separate chart and see how it evolves form there, how popular it is, how many contributions it gets etc 😃 |
Description
Add Git Sync support to locust chart to easily deploy multiple locustfiles.
Checklist
[stable/mychartname]
)