Description of problem: add one env variable named cartridge-level variables like 'OPENSHIFT_POSTGRESQL_DB_PORT'. And then add postgresql cartridge, it will be failed and show 'Could not start Postgres' Version-Release number of selected component (if applicable): devenv_3677 How reproducible: always Steps to Reproduce: 1. create one app 2. add one env variable named 'OPENSHIFT_POSTGRESQL_DB_PORT' curl -k -H 'Accept: application/xml' --user zzhao:redhat https://ec2-107-22-22-100.compute-1.amazonaws.com/broker/rest/applications/817232a8097a11e3b0fa22000ab30f72/environment-variables -X POST -d name=OPENSHIFT_POSTGRESQL_DB_PORT -d value=333 3. add postgresql cartridge for this app rhc cartridge add -a app -c postgresql-8.4 Actual results: step:3 rhc cartridge add -a zqphps -c postgresql-8.4 Adding postgresql-8.4 to application 'zqphps' ... Could not start Postgres Expected results: should be added successfully and OPENSHIFT_POSTGRESQL_DB_PORT will be covered with new value Additional info:
Any env variables that will be written under .env dir during cartridge configure/post-configure/some other operation should delete those variables from .env/user_vars dir.
Overriding this variables is a feature of user variables. Using correct values is up to the user.