-
Notifications
You must be signed in to change notification settings - Fork 90
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
chore(local-dev): add node affinity on the patches for local dev with EC #5002
base: main
Are you sure you want to change the base?
Conversation
You can use the EC_NODE env var to connect to a different node than node0:
This is because you can have multiple clusters and kotsadm should not necessarily always run on node0. |
Right but even if you do, for this to work, you need to run
Else the deployment will likely fail with pull image backoff errors if the pod lands on a node where the image isn't available. I thought it would just be easier to pin the deployment to a single node when doing local dev as way to overcome this. |
How about we pin it to the value of |
Ah got it, yeah that makes sense. I can look into that 👍 |
Done @sgalsaleh. Let me know what you think. |
Actually, this same patch is used for existing cluster (vanilla KOTS dev env), which I don't believe will work as the node is not named the same way. |
Good catch. Went with a different approach, let me know what you think. |
What this PR does / why we need it:
When running local dev with embedded cluster, running
make kotsadm-up-ec
will build the local dev images and load them intonode0
(by default). If we're running a multi node cluster setup it so happens that the scheduled pods might land in any of the other nodes other thannode0
(which won't have the loaded image). This affinity ensures we always schedule the pods on the correct node we set usingEC_NODE
env var.Which issue(s) this PR fixes:
NONE
Does this PR require a test?
NONE
Does this PR require a release note?
Does this PR require documentation?
NONE