Symfony2环境变量

Symfony2环境变量,symfony,amazon-web-services,amazon-elastic-beanstalk,Symfony,Amazon Web Services,Amazon Elastic Beanstalk,我试图在Symfony2中使用环境变量作为参数。但是,当我运行composer update时,我得到: [Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException] You have requested a non-existent parameter "compass.bin". 变量“SYMFONY\uuuu COMPASS\uuuu BIN”在shell和apachevhost中都有设置

我试图在Symfony2中使用环境变量作为参数。但是,当我运行composer update时,我得到:

 [Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException]  
 You have requested a non-existent parameter "compass.bin".
变量“SYMFONY\uuuu COMPASS\uuuu BIN”在shell和apachevhost中都有设置。你知道这是什么原因吗

更新
似乎问题是特定于弹性Beanstalk的-不仅compass.bin,而且所有其他环境变量都不可见(尽管在容器中设置并通过ssh可见)。

我通过禁用composer安装挂钩成功地解决了问题。当供应商文件夹存在时,它不会运行(我在这里找到了这个提示:)。然后,我简单地将自己的命令添加到.ebextensions,该命令使用环境变量运行composer install。

引入环境变量后是否清除缓存?能否将
config.yml
部分发布到引用该变量的位置?当然,这里是:assetic:debug:%kernel.debug%”使用\u controller:false filters:cssrerewrite:~sass:~compass:bin:“%compass.bin%”将\u应用于:“\.scss$”如何为CLI部署和设置环境变量?是否有一种方法可以验证在运行EB deploy时变量是否可见?一个简单的作曲家胡克就可以了。我也在使用安德鲁·马辛克维奇乌斯的帖子,它有一个很好的概述。我和作曲家还有一些其他问题,但现在解决了。我在我的供应商文件夹中使用了他建议的.gitkeep,其中没有其他内容。部署过程中可能会出现很多问题!