origin icon indicating copy to clipboard operation
origin copied to clipboard

The oc set resources command should work for buildconfigs.

Open GrahamDumpleton opened this issue 8 years ago • 5 comments

Should be able to use oc set resources on buildconfigs.

$ oc set resources bc/blog --limits memory=786Mi
error: buildconfigs/blog the object is not a pod or does not have a pod template
Version
oc v3.6.1+008f2d5
kubernetes v1.6.1+5115d708d7
features: Basic-Auth

Server https://api.pro-us-east-1.openshift.com:443
openshift v3.6.173.0.21
kubernetes v1.6.1+5115d708d7
Steps To Reproduce

Run oc set resources on a build config.

Current Result

Will fail.

Expected Result

Should be able to work.

Additional Information

None.

GrahamDumpleton avatar Nov 14 '17 21:11 GrahamDumpleton

@juanvallejo @fabianofranz is this something you guys would be willing/able to do? The buildconfig has resources fields already.

(i'm going to take @juanvallejo's self assignment of this as a yes. Thanks @juanvallejo!)

bparees avatar Nov 14 '17 21:11 bparees

Issues go stale after 90d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle stale. Stale issues rot after an additional 30d of inactivity and eventually close. Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle stale

openshift-bot avatar Feb 25 '18 11:02 openshift-bot

/lifecycle frozen

GrahamDumpleton avatar Feb 26 '18 02:02 GrahamDumpleton

Hi! Did you solve the proplem? I still get the error: oc set resources bc/test --limits=cpu=1,memory=1Gi error: {build.openshift.io v1 buildconfigs}/test the object is not a pod or does not have a pod template: *v1.BuildConfig

openshift v3.11.129 kubernetes v1.11.0

DanilaSobolev avatar Sep 18 '19 18:09 DanilaSobolev

@DanilaSobolev use 'oc patch ...' instead, example:

oc patch bc/${BC_NAME} -p '{"spec":{"resources":{"limits":{"cpu": "1000m", "memory": "2Gi"}}}}'

patlachance avatar Nov 16 '19 06:11 patlachance