---
<%
    require 'dotenv'
    Dotenv.load
%>

driver:
  # name: ec2
  # associate_public_ip: false
  # instance_type: <%= ENV['EC2_INSTANCE_TYPE'] || 't3.medium' %>
  # interface: private
  # region: <%= ENV['AWS_REGION'] || 'us-east-1' %>
  # security_group_filter:
  #   name: <%= ENV['EC2_SECURITY_GROUP_NAME'] || 'dev-test-kitchen-instance-security-group' %>
  # skip_cost_warning: true
  # subnet_filter:
  #   tag: Name
  #   value: <%= ENV['EC2_SUBNET_NAME'] || 'private01' %>
  name: vcenter
  vcenter_username: <%= ENV['VCENTER_USER'] %>
  vcenter_password: <%= ENV['VCENTER_PASSWORD'] %>
  vcenter_host: 'ny-vsphere01.theorchard.local'
  vcenter_disable_ssl_verify: true
  vm_wait_timeout: 300
  vm_customization:
    annotation: 'irrigate-ecs test kitchen VM'

provisioner:
  name: chef_zero
  product_name: chef
  product_version: 18.2.7 
  chef_license: accept

verifier: 
  name: inspec

platforms:
  #- name: amazon2-2023 # for ec2
  - name: amazonlinux-2
    driver:
      template: _Templates/amazonlinux2-vmware
      datacenter: "ny-vsphere-dc"
    transport:
      username: "ec2-user"
      ssh_key: <%= ENV['VCENTER_SSH_KEY'] %>

suites:
  - name: default
    run_list:
      - recipe[irrigate-ecs::ssm]
      - recipe[irrigate-ecs::exec]
      - recipe[irrigate-ecs::default]
    attributes:
      ecs:
        cluster_name: ECS-anywhere-POC
        map_tag: server-1234
      ssm:
        activation_credentials_data_bag_name: ssm_activation
        use_default_data_bag_secret_file: true
    encrypted_data_bag_secret_key_path: <%= ENV['ENCRYPTED_DATA_BAG_SECRET_KEY_PATH'] || '/etc/chef/encrypted_data_bag_secret' %>
    roles_path: ../../roles
    data_bags_path: <%= ENV['DATA_BAGS_PATH'] || '../../data_bags' %>
    verifier:
      inspec_tests:
        - test/integration/default
