【问题标题】:Copy elastic beanstalk configuration to an environment in another region将弹性 beanstalk 配置复制到另一个区域的环境中
【发布时间】:2020-05-09 13:59:43
【问题描述】:

我已经使用 AWS Web 控制台设置了一个弹性 beanstalk 应用程序和环境。现在我需要将此环境的配置复制到不同区域的另一个环境中。 有没有办法做到这一点。 任何人都可以帮助我提供详细的文档吗?

【问题讨论】:

    标签: git amazon-web-services amazon-elastic-beanstalk aws-cli


    【解决方案1】:

    您可以通过以下方式将一个弹性 beanstalk 环境配置从一个区域复制到另一个区域。

    I - 保存环境的配置

    1. Open the Elastic Beanstalk console
    2. Navigate to the management page for your environment.
    3. Choose Actions, and then choose Save Configuration.
    4. Use the on-screen form to name the saved configuration. Optionally, provide a brief description, and add tag keys and values.
    5. Choose Save.
    

    II - 使用第一个区域中的环境初始化 EB CLI

    III - 下载保存的配置

    1. You can download a configuration using the EB CLI eb config command, as shown in the following example.
            `eb config get NAME`        ; where NAME is the name of your saved configuration.
    

    IV - 使用第二个区域中的环境初始化 EB CLI

    V - 将配置文件上传到另一个区域的 Elastic bean stalk 环境

    1. You can upload a configuration file using following command.
            `eb config put filename`    ; where `filename` is the name of configuration file without the full path. 
                                            The filename must have the file extension .cfg.yml
        (Now you can see the configuration in `Saved configuration` in the second environment )
    

    VI - 在环境创建期间应用保存的配置(Elastic Beanstalk 控制台)

    1. Open the Elastic Beanstalk console.
    2. Choose an application.
    3. Choose Saved Configurations.
    4. Choose a saved configuration, and then choose Launch environment.
    5. Proceed through the wizard to create your environment.
    

    【讨论】:

    • 感谢您的回答。但是当我尝试上传我的配置时收到错误“错误:InvalidParameterValueError -”。我尝试只使用文件名、相对路径、绝对路径,但它们都不起作用。你有什么想法吗?
    猜你喜欢
    • 2014-02-11
    • 2019-07-05
    • 2021-06-15
    • 1970-01-01
    • 2016-05-16
    • 2015-10-16
    • 1970-01-01
    • 2023-03-03
    • 1970-01-01
    相关资源
    最近更新 更多