Description of problem: Given Docker and custom Build strategy are not allowed like in On line environment, when users try to modify strategy from 'Source' to 'Docker', There is a forbidden message. But when users try to modify strategy from 'Source' to 'Custom'. There is a successful message, In fact the modification is not saved successfully. Version-Release number of selected component (if applicable): atomic-openshift-3.3.0.32-1.git.0.37bd7ea.el7.x86_64 docker-1.10.3-46.el7.14.x86_64 kernel-3.10.0-327.36.1.el7.x86_64 How reproducible: Always Steps to Reproduce: 1.In web console build page, click 'Action' ->Edit YAML to change strategy form 'Source' to 'Custom', negative test: only update 'type' filed, not update 'customStrategy' type: Source # --> Change to Custom 2.Click save; 3.Edit Yaml to check if the modification is saved. Actual results: 2. The system prompts'....bulid was updated'; Expected results: 2. Should prompt '...build is forbidden. Build strategy Custom is now allowed.' Additional info: With above modification, CLI oc edit has same result.
It looks like you may be misunderstanding what is happening when you are changing the values in the YAML file. When you change the strategy type to "Custom" and leave the line below it as sourceStrategy (which is allowed), the value is automatically being converted back to "Source", it's not that it just isn't being saved and not erroring. You can test this by changing the YAMl config as in the below examples, and you will get the correct error or either custom build strategy not allowed, or docker build strategy not allowed. strategy: type: Custom dockerStrategy: or strategy: type: Custom customStrategy: or strategy: type: Source customStrategy: Basically the server is trying to fix the mistake itself when it can. Please let me know if this makes sense or if you need further clarification.
Please feel free to re-open this bug if you have further comments or questions about it.