【问题标题】:Setting environment variables for multiple apps at the same time in Heroku?在 Heroku 中同时为多个应用程序设置环境变量?
【发布时间】:2013-08-23 07:40:18
【问题描述】:

我想设置环境。 vars 同时用于多个应用程序。像这样的:

heroku config:set VAR='whatever' --app heroku-app-1, heroku-app-2 …或者…

heroku config:set VAR='whatever' --app heroku-app-1 --app heroku-app-2?

这可能吗?

干杯!

【问题讨论】:

    标签: heroku environment-variables


    【解决方案1】:

    标准 API 客户端没有办法,但是插件 heroku-wildcards 增加了这个功能。

    heroku plugins:install https://github.com/tpope/heroku-wildcards.git
    

    然后就可以运行了

    heroku config:set VAR='whatever' --app heroku-app-1,heroku-app-2
    

    或者

    heroku config:set VAR='whatever' --app heroku-app-*
    

    【讨论】:

      猜你喜欢
      • 2021-12-23
      • 2015-04-04
      • 2021-06-01
      • 2020-07-02
      • 1970-01-01
      • 2020-10-30
      • 1970-01-01
      • 2016-10-08
      • 2014-08-02
      相关资源
      最近更新 更多