cf icon indicating copy to clipboard operation
cf copied to clipboard

cf push --reset does not send updated environment variables in the manifest.yml

Open bhattala opened this issue 12 years ago • 2 comments

If an application is pushed using "cf push", with a manifest.yml defining various values (but without defining any environment variables), then a subsequent push after editing the manifest.yml to include some environment variables does not send these new values, even if "cf push --reset" is used.

I have confirmed that --reset does send an altered "memory" value, but that my environment variables are not sent. Deleting the application via "cf delete myapp" and then pushing with the variables present in a manifest.yml does send the values, hence I am using a correctly formatted manifest.yml. However, re-pushing an app using the --reset option, with an updated manifest.yml that contains environment values where none were present on the first push does not seem to be behaving correctly.

I've also confirmed this using the --trace option. Here is a snippet from the output produced when using the --trace option in the scenario where I am re-pushing using an updated manifest.yml, "environment_json": { }, and here is a snippet when pushing an app for the first time with the manifest.yml containing some environment variables, "environment_json": { "IBM_JVM_LICENSE": "L-AWON-8GALN9", "IBM_LIBERTY_LICENSE": "L-JTHS-95XRL8" },

I expect to see the latter on a push using --reset once I have added these variables to the manifest.yml, but see the former (i.e. the variables are not sent).

This issue is somewhat similar to Issue #45 "cf push --reset does not forget custom command", but for environment variables rather than a command.

bhattala avatar Nov 06 '13 11:11 bhattala

Here are the gem versions I am using :

$ gem list cf

*** LOCAL GEMS ***

cf (5.4.1) cf-uaa-lib (2.0.0) cfoundry (4.5.3)

bhattala avatar Nov 06 '13 11:11 bhattala

Hi,

I reproduced this issue here, and it will be added to the backlog for cf internally. Unfortunately, bugs in this repository are a low priority for us right now, since we are moving towards version 6 (https://github.com/cloudfoundry/cli). You should be able to able to work around this by specifying environment variables in the command line.

Best,

@ruthie @charliebevis

ruthie avatar Nov 12 '13 21:11 ruthie