Skip to content
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

Please add support for (anti)affinity for all deployments, etc #133

Closed
lhriley opened this issue Jan 13, 2023 · 1 comment · Fixed by #170
Closed

Please add support for (anti)affinity for all deployments, etc #133

lhriley opened this issue Jan 13, 2023 · 1 comment · Fixed by #170
Labels
tracked Issue is tracked in 1Password's internal ticketing system as well.

Comments

@lhriley
Copy link
Contributor

lhriley commented Jan 13, 2023

Summary

Please include the option to define pod placement using affinity:
https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity

Use cases

We have specific node pools dedicated to different resource requirements, and we place our pods using node / pod affinity. This is much more flexible than using nodeSelector for our purposes.

Proposed solution

Change these (and any I missed):

{{- with .Values.operator.nodeSelector }}
nodeSelector:
{{ toYaml . | indent 8 }}
{{- end }}
tolerations:
{{ toYaml .Values.operator.tolerations | indent 8 }}

{{- with .Values.connect.nodeSelector }}
nodeSelector:
{{ toYaml . | indent 8 }}
{{- end }}

to:

      {{- with .Values.<deployment>.nodeSelector }}
      nodeSelector:
        {{- toYaml . | nindent 8 }}
      {{- end }}
      {{- with .Values.<deployment>.affinity }}
      affinity:
        {{- toYaml . | nindent 8 }}
      {{- end }}
      {{- with .Values.<deployment>.tolerations }}
      tolerations:
        {{- toYaml . | nindent 8 }}
      {{- end }}

Is there a workaround to accomplish this today?

n/a

References & Prior Work

@jillianwilson
Copy link
Contributor

Hi there, I logged this internally to implement this. However, I can't give a timeline for when this can be completed. Please feel free to make a PR for this if you wish :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tracked Issue is tracked in 1Password's internal ticketing system as well.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants