dongyuedaochen8415
dongyuedaochen8415
2015-06-18 17:36

连接后,eb cli 3.0没有从我现有的环境中设置我的设置

已采纳

I created a customized Elastic Beanstalk environment from the web interface with configuration for VPC and other things. I now have a local repo that I want to connect to this created environment.

I ran eb init and was able to spot my environment and selected it.

I then ran eb deploy and it succesfully deployed my repo to my instances.

My confusion now is with regards to the option files. I thought eb init was supposed to fetch my configuration from the web interface and save it locally to .elasticbeanstalk?

The only thing it did right now is created a file .elasticbeanstalk/config.yml

branch-defaults:
  staging:
    environment: test-staging-env
global:
  application_name: test-staging
  default_ec2_keyname: test-staging-kp
  default_platform: php
  default_region: us-east-1
  profile: eb-cli
  sc: git

1) Where can I put my configuration for things such as

[aws:elasticbeanstalk:container:php:phpini]
allow_url_fopen=On
composer_options=--no-dev
display_errors=Off
document_root=/public
max_execution_time=60
memory_limit=256M
zlib.output_compression=Off

2) How can I fetch the configuration details done through the web interface to a file?

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享
  • 邀请回答

1条回答

  • doujuncuo9339 doujuncuo9339 6年前

    eb init grabs the basic settings from your currently running environment. This includes:

    • Platform
    • Keypair name

    Everything else is environment specific. If you would like to save your environments configuration to a file, you can use

    eb config save
    

    Typically, you can edit the configurations in place by using

    eb config
    

    You shouldn't need a file. But if you prefer to put those settings in a file you can create an ebextension file. Create a directory called .ebextensions and a file called [somename].config. Put the option settings in that file.

    点赞 评论 复制链接分享

相关推荐