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

Default Affinity Settings - Distribute across nodes. #104

Open
straubt1 opened this issue Nov 18, 2024 · 1 comment
Open

Default Affinity Settings - Distribute across nodes. #104

straubt1 opened this issue Nov 18, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@straubt1
Copy link

Challenge

Desire to have TFE Pods to be automatically distributed across the available nodes.

In our experience without adding an affinity to our overrides, there is a chance that the 2 of the replicas will land on a single node.

Environment

GKE

  • 3 Control Nodes (n2-standard-4)

TFE Helm

  • replicaCount: 3

Recommendation

Update the default to something like below to avoid the need to pass this in from the overrides (what I would argue is the typical expected behavior in production).

affinity:
  podAntiAffinity:
    requiredDuringSchedulingIgnoredDuringExecution:
      - labelSelector:
          matchExpressions:
            - key: app
              operator: In
              values:
                - terraform-enterprise
        topologyKey: "kubernetes.io/hostname"
@carlosvilleg
Copy link

topologyKey: "kubernetes.io/zone" would be better in general

@aaron-lane aaron-lane added the enhancement New feature or request label Nov 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants