Cloudify:此用户没有默认 VPC

Cloudify: No default VPC for this user

我正在浏览 Cloudify 文档并尝试将其部署到我们的 AWS

我确实从 GitHub

中检查了 Cloudify Manager Blueprint 的最新代码

更新了 inputs.yaml 文件,当我 运行 使用命令时:

cfy bootstrap -p aws-ec2-manager-blueprint.yaml -i inputs.yaml --task-retries 10

它通过了所有验证步骤、生成密钥、安全组,然后给我抛出很多错误:

NonRecoverableError: EC2ResponseError: 400 Bad Request
<?xml version="1.0" encoding="UTF-8"?>
<Response>
    <Errors>
        <Error>
            <Code>VPCIdNotSpecified</Code>
            <Message>No default VPC for this user</Message>
        </Error>
    </Errors>
    <RequestID>some-blah-blah-blah</RequestID>
</Response>

谁能建议我应该在哪个标签下的哪个配置中指定 VPS 我想使用? 我也没有在 AWS AMI 中找到任何如何为每个特定用户设置默认 VPC 的信息——因为我确实使用访问密钥

创建了 Cloudify-bot 服务帐户

我做错了什么?

似乎没有分配默认VPC。谷歌搜索我发现了这个:

"If you created your AWS account after 2013-12-04, it supports only EC2-VPC. In this case, you'll have a default VPC in each AWS region."

看来您可能需要创建一个新的 VPC 并将其指定为默认 VPC。

http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/getting-started-create-vpc.html

关于默认 VPC 和子网:
如果您删除了默认 VPC 并使用子网创建了自己的自定义 VPC,则无法将其设为默认。 这是来自 official AWS documentation 的引述:

You cannot mark an existing VPC as a default VPC. If you delete a default subnet and then need to restore it, create a new subnet in your default VPC, and then contact AWS Support to mark the subnet as a default subnet.

关于 Cloudify 和自定义 VPC 处理:
自定义 VPC 处理似乎可以通过 "AWS VPC Plugin" 获得,它仅属于 Pro version - 付费版本,而不是开源。更重要的是,它被标记为仅包含在 Cloudify v3.3 中——当前版本是 v3.2——所以它似乎还没有准备好

功能似乎发生了变化。 2017 年 12 月,我在使用 packer 创建 EC2 机器时 运行 进入 "No Default VPC for user"。我能够从 VPC 下的 AWS 控制台创建一个新的 VPC。有一个按钮 "Create Default VPC"。我按下它,中提琴 - 我可以再次创造机器。

由于 Google 在 2019 年 5 月将我带到这里作为最佳答案,我正在确认 David Resnick 上面指出的内容。 Creating a default VPC