<p>I have 3 cpu nodes and 1 gpu node on my cluster. As a default, the
projects should deploy to the cpu nodes and only when specified to the
gpu nodes. I added <code>defaultNodeSelector: "graphic=cpu"</code> to the
projectConfig section in <code>master-config.yaml</code> to achieve this purpose.</p>

<p>The problem now when i create a deploymentConfig and assign it to the gpu
node using node selector, I get the error <code>pod node label selector conflicts with its project node label selector</code>.</p>

<p>I tried removing the defaultNodeSelector line and added
<code>nodeSelectorLabelBlacklist: - graphic=gpu</code> to the PodNodeConstraints
section in <code>master-config.yaml</code>, but this did not work at all. Despite this
config the pods of the default projects got scheduled to the gpu node :/</p>

<p><a href="https://pastebin.com/v88Lc73x" rel="nofollow noreferrer">master-config.yaml</a></p>

<p>Does any body has an Idea how to achieve such stuff?</p>

alixander
<p>You have set here a cluster-wide configuration which cannot be overridden at the Pod level.</p>

<p>Probably, the simplest fix in this instance, assuming you have other projects that want to leverage the cluster-wide config is to edit the namespace for this particular project and set the <code>openshift.io/node-selector: ""</code>.</p>

<p>For each workload in this project then set the desired node as appropriate in each deployment or deploymentconfig. That should fix the issue for you.</p>

<p>Perhaps, if this is not a one off case for you, take a look at other scheduling features such as <a href="https://docs.openshift.com/container-platform/3.11/admin_guide/scheduling/taints_tolerations.html" rel="nofollow noreferrer">taints and tolerations</a> or <a href="https://docs.openshift.com/container-platform/3.11/admin_guide/scheduling/pod_affinity.html" rel="nofollow noreferrer">pod affinity</a> </p>
