سؤال

I need to set up consumer key and secrets for Github, Twitter and Facebook.

On version 1 of Cloud Foundry you could do vmc env-add NAME=VALUE Now with the cf gem I see I can do cf env but thats it. I also tried setting a .env file and repushing with no success

هل كانت مفيدة؟

المحلول 2

It looks like you can do a cf set-env (https://github.com/cloudfoundry/cf/blob/master/lib/cf/cli/app/env.rb). You can also always do a cf help --all, which will show you all the commands you can use.

نصائح أخرى

In addition, you can set environment variables in an application manifest file.

Here is an example of how to do so (see the env section of the manifest with name/value pairs)

---
applications:
- name: app1
  env:
    ENV_VAR_1: MYVALUE
    ENV_VAR_2: ZZZ
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top