Bug 1884580

Summary: Normal user can't create job from exist cronjob
Product: OpenShift Container Platform Reporter: Maciej Szulik <maszulik>
Component: kube-controller-managerAssignee: Maciej Szulik <maszulik>
Status: CLOSED ERRATA QA Contact: RamaKasturi <knarra>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.5CC: aos-bugs, erich, knarra, maszulik, mfojtik, mzali, sparpate, yinzhou
Target Milestone: ---   
Target Release: 4.5.z   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: 1835066 Environment:
Last Closed: 2020-11-05 12:46:58 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On: 1835066    
Bug Blocks: 1884569    

Comment 2 RamaKasturi 2020-10-23 07:13:35 UTC
Verified with the payload below and i see that normal user could create cronjob and job.

[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-10-23-025638]$ ./oc version -o yaml
clientVersion:
  buildDate: "2020-10-22T08:26:12Z"
  compiler: gc
  gitCommit: 6082e941e6d62f3a0c6ca8ba52927100948b1d0d
  gitTreeState: clean
  gitVersion: openshift-clients-4.5.0-202006231303.p0-18-g6082e941e
  goVersion: go1.13.4
  major: ""
  minor: ""
  platform: linux/amd64
releaseClientVersion: 4.5.0-0.nightly-2020-10-23-025638
serverVersion:
  buildDate: "2020-10-22T05:11:10Z"
  compiler: gc
  gitCommit: 70b8a93
  gitTreeState: clean
  gitVersion: v1.18.3+70b8a93
  goVersion: go1.13.4
  major: "1"
  minor: 18+
  platform: linux/amd64

[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-10-23-025638]$ ./oc new-project test
Now using project "test" on server "https://api.knarra1023.qe.devcluster.openshift.com:6443".

You can add applications to this project with the 'new-app' command. For example, try:

    oc new-app ruby~https://github.com/sclorg/ruby-ex.git

to build a new example application in Ruby. Or use kubectl to deploy a simple Kubernetes application:

    kubectl create deployment hello-node --image=gcr.io/hello-minikube-zero-install/hello-node

[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-10-23-025638]$ ./oc create cronjob my-job --image=openshift/hello-openshift --schedule=\*\ 5\ \*\ \*\ \?
cronjob.batch/my-job created
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-10-23-025638]$ ./oc create job hello-job --from=cronjob/my-job
job.batch/hello-job created
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-10-23-025638]$ ./oc get cronjob
NAME     SCHEDULE    SUSPEND   ACTIVE   LAST SCHEDULE   AGE
my-job   * 5 * * ?   False     0        <none>          27s
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-10-23-025638]$ ./oc get job
NAME        COMPLETIONS   DURATION   AGE
hello-job   0/1           16s        16s

Based on the above moving bug to verified state.

Comment 5 errata-xmlrpc 2020-11-05 12:46:58 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (OpenShift Container Platform 4.5.17 bug fix update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:4325