-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Allow setting default execution group pod spec #11395
Allow setting default execution group pod spec #11395
Conversation
@jlanda mentioned it may be easier to use |
the operator does have some pain points with |
Hypothetical CR to use w/ operator to make this work:
I'm realizing to specify a different namespace here in the pod spec, we would need to also create a k8s bearer token credential and associate that with the container group. But I think that can be addressed in a seperate PR |
1f37d6d
to
e3d34a7
Compare
Ok finally got this working. Turned out we needed to use the Creating my AWX Cr with this:
And having previously added this label to a node on a cluster, I see that the job pod gets created with:
That node being the one where the label had been added. 🚀 Can now say I'm confident this PR allows adding node affinity/node selectors to the pod spec w/o having to also provide any other info that is normally set by AWX. In a future PR I will consider what is necessary if we want to be able to use a different namespace + configure at deploy time a credential for using that namespace. |
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 like this a lot, but we've got to hold off (probably until tomorrow afternoon) on merging this. I'll make a note to come back when we're in the clear to merge.
This will allow us to control the default container group created via settings, meaning we could set this in the operator and the default container group would get created with it applied. We need this for ansible/awx-operator#242 Deepmerge the default podspec and the override With out this, providing the `spec` for the podspec would override everything contained, which ends up including the container used, which is not desired Also, use the same deepmerge function def, as the code seems to be copypasted from the utils
e3d34a7
to
e10030b
Compare
This will allow us to control the default container group created via settings, meaning
we could set this in the operator and the default container group would get created with it applied.
We need this for being able to apply things like node labels etc to the default container group pod spec at install time, which is one part of ansible/awx-operator#242