"oc create job" fails with "cannot set blockOwnerDeletion if an ownerReference refers to a resource you can't set finalizers on"
Issue
-
When using the
oc
client with version 4.15 orkubectl
version 1.28, manually creating a job from a cronjob as a regular user fails with the following error message:$ oc version Client Version: 4.15.6 Kustomize Version: v5.0.4-0.20230601165947-6ce0bf390ce3 Kubernetes Version: v1.28.7+f1b5f6c $ oc create job manual-job --from=cronjob/pi error: failed to create job: jobs.batch "manual-job" is forbidden: cannot set blockOwnerDeletion if an ownerReference refers to a resource you can't set finalizers on: , <nil>
Environment
- Red Hat OpenShift Container Platform (RHOCP) 4.15
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.