Description of problem: When create app from source code or from template, on creation page, there is no asterisk to highlight the parameter that must be defined. Such as the app name is required but not highlighted on creation page from source code. Version-Release number of selected component (if applicable): devenv_fedora_2115 $ oc version oc v1.0.4-88-ga2ad7d7 kubernetes v1.0.0 How reproducible: Always Steps to Reproduce: 1.Create images in openshift project $ oc create -f /data/src/github.com/openshift/origin/examples/image-streams/image-streams-centos7.json -n openshift 2.Create templates in project. $ oc create -f /data/src/github.com/openshift/origin/examples/sample-app/application-template-stibuild.json -n protest 3.On web console, when create app using the template, check the creation page. 4.On web console, when create app using source code, check the creation page. Actual results: 3.On the creation page, there are many parameters required, but no asterisk to highlight them. User would forget to define some parameters. 4 On the creation page, there is no asterisk to prompt the parameter is required. Expected results: 3,4.Should have asterisk to prompt user the parameter is required. Additional info:
We've previously added an asterisk for required template parameters: https://github.com/openshift/origin/issues/3984 https://github.com/openshift/origin/pull/3986 Can you try in a newer build?
Required template parameters are done. Name and Replicas are not yet marked as required on the last create from source page.
Checked on devenv_fedora_2129, the code from pull 3986 has been merged on the test env, but still no asterisk found on creation page. Could you help check what's the issue, Samuel?
Created attachment 1061015 [details] Modified ruby hello world template
The parameter needs to be marked as required in the template. Can you check? A required parameter looks like { "name": "MYSQL_DATABASE", "description": "database name", "value": "", "required": true } You can see with the command oc get template <name> -o json -n <namespace> I've also attached a template with required parameters.
Test with the template with required parameters, and there are asterisks on creation page now. So example templates under origin/example/ need to be updated accordingly.
(In reply to Yanping Zhang from comment #6) > Test with the template with required parameters, and there are asterisks on > creation page now. So example templates under origin/example/ need to be > updated accordingly. Ben ^^
Sam are you just asking that i go update fields in the existing templates to add the "required=true" flag?
Ben, not necessarily. Just making you aware of this bug and seeing if we plan to add required to those templates.
I didn't have any plans to do so.. not that it would be necessarily wrong to, but the real use case for "required" is a field that is by default empty, but needs a value to be provided. in our db templates, the fields need a value, but we provide a default one. So unless the user goes in and explicitly deletes/overrides the default value with an empty string, they won't have problems.
I'm concerned about the user experience when you do happen to remove that value, though. Only some of the template resources are created, and you have to figure out how to delete things and start over. It's very easy to catch before submit if required is set.
The resources all get created. but the DB pod (for example) will fail to start citing the lack of a DB_NAME/USER/PASSWORD.
In a way that's worse because it looks like everything succeeded. Would a user know what's wrong and how to fix it? It just seems like it could be easily avoided.
I believe the all required fields now have the asterisk.
Checked on devenv-fedora_2517. openshift v1.0.6-833-ga7032bc kubernetes v1.2.0-alpha.1-1107-g4c8e6f4 etcd 2.1.2 When create app on web console, on creation page, all required fields now have the asterisk. Move the bug to Verified.