Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1511289 - Adding negative value to resource quota yaml file while Setting Limits for Users and Projects.
Summary: Adding negative value to resource quota yaml file while Setting Limits for Us...
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Command Line Interface
Version: 3.6.0
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: ---
: ---
Assignee: Fabiano Franz
QA Contact: Xingxing Xia
URL:
Whiteboard:
: 1511290 1511291 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-11-09 05:32 UTC by kavitha
Modified: 2017-11-10 02:42 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-11-10 02:42:19 UTC


Attachments (Terms of Use)

Description kavitha 2017-11-09 05:32:09 UTC
Description of problem:
Adding negative value to resource quota yaml file while Setting Limits for Users and Projects: while creating quota where persistent volume claim given with negative values 
I could execute the command successfully without any error.

Version-Release number of selected component (if applicable):
atomic-openshift-utils-3.6.173.0.48-1.git.0.1609d30.el7.noarch

How reproducible:
resource-quota.yaml

apiVersion: v1
kind: ResourceQuota
metadata:
  name: core-object-counts
spec:
  hard:
    configmaps: "10"
    persistentvolumeclaims: "-4"
    replicationcontrollers: "20"
    secrets: "10"
    services: "10"


Steps to Reproduce:
1.login to Openshift CLI 
2.oc create -f resource-quota.yaml


Actual results:
It is successfully executing and creating quota.

Expected results:
It should throw the error after detecting the negative value

Additional info:

Comment 1 kavitha 2017-11-09 05:48:35 UTC
*** Bug 1511291 has been marked as a duplicate of this bug. ***

Comment 2 kavitha 2017-11-09 05:49:20 UTC
*** Bug 1511290 has been marked as a duplicate of this bug. ***

Comment 3 Xingxing Xia 2017-11-09 06:11:57 UTC
Thanks, but it is not reproduced in both try of oc/OCP v3.6.173.0.65 and oc/OCP v3.7.0-0.198.0, which both work and give prompt well:
$ oc create -f resource-quota.yaml --config path/to/admin.kubeconfig -n my-proj
The ResourceQuota "core-object-counts" is invalid: spec.hard[persistentvolumeclaims]: Invalid value: "-4": must be greater than or equal to 0

Hmm, what makes 1511291 1511290 submitted concurrently?

Comment 4 Fabiano Franz 2017-11-09 19:03:29 UTC
Unable to reproduce.

Comment 5 Xingxing Xia 2017-11-10 02:42:19 UTC
Per above commented results, it works for us, closing it. Thank you all


Note You need to log in before you can comment on or make changes to this bug.