Chef infra 如何在测试厨房中使用带有ec2驱动程序的自定义AMI?

Chef infra 如何在测试厨房中使用带有ec2驱动程序的自定义AMI?,chef-infra,test-kitchen,Chef Infra,Test Kitchen,我不确定我遗漏了什么,但我的定制CentOS AMI被test ktichen忽略了。它没有旋转正确的AMI,而是旋转一个Ubuntu AMI。这是我的厨房 --- driver: name: ec2 aws_ssh_key_id: chef security_group_ids: ["sg-b57021c0", "sg-fga04293"] subnet_id: subnet-58721c1d region: us-east-2 require_chef_omnibus

我不确定我遗漏了什么,但我的定制CentOS AMI被test ktichen忽略了。它没有旋转正确的AMI,而是旋转一个Ubuntu AMI。这是我的厨房

---
driver:
  name: ec2
  aws_ssh_key_id: chef
  security_group_ids: ["sg-b57021c0", "sg-fga04293"]
  subnet_id: subnet-58721c1d
  region: us-east-2
  require_chef_omnibus: true
  instance_type: t2.micro
  associate_public_ip: true


provisioner:
  name: chef_zero
  policyfile: Policyfile.rb

platforms:
  - name: import-ami-ffpxv46d
    image_id: ami-ffpxv46d
    transport:
      ssh_key: /user/ami.pem
      username: root

suites:
  - name: default
    provisioner:
      policyfile: Policyfile.rb

您必须将
图像\u id
放在驱动程序配置下,如下所示:

platforms:
  - name: import-ami-ffpxv46d
    driver:
      image_id: ami-ffpxv46d
    transport:
      ssh_key: /user/ami.pem
      username: root

否则TK会将其视为实例配置的一部分。

您必须将
图像\u id
放在驱动程序配置下,如下所示:

platforms:
  - name: import-ami-ffpxv46d
    driver:
      image_id: ami-ffpxv46d
    transport:
      ssh_key: /user/ami.pem
      username: root

否则TK会将其视为实例配置的一部分。

谢谢您,先生!工作完美:)这似乎是错误的记录在厨房的一部分-ec2自述,我会得到修复。谢谢先生!工作完美:)这似乎是错误地记录在厨房-ec2自述的一部分,我会得到修复。