I want to create projects on a particular node on openshift using the rest api.
I call the openshift api /oapi/v1/projectrequests
to create projects. And in the body I am sending,
body:
{
apiVersion: 'v1',
kind: 'ProjectRequest',
metadata: {
name: projectName,
annotations: {
"openshift.io/node-selector": "servicelevel=botifyproject",
}
},
This api runs successfully, project gets created but when I run the command, oc describr project <project-name>
it doesn't show me anything that says it is inside the botifyproject node selector.
Is this the wrong way of doing this?