---
libvirt-server:
  hooks:
    postup:
      - name: install_linchpin
        type: ansible
        context: True
        actions:
          - playbook: install.yaml
            extra_vars: 
              ansible_ssh_private_key_file: "/workDir/workspace/ci-linchpin/linchpin/keys/linchpin_libvirt_key.pem"
              ansible_ssh_user: centos
      - name: run_linchpin_libvirt_tests
        type: ansible
        context: True
        actions:
          - playbook: run_tests.yaml
            extra_vars:
              ansible_ssh_private_key_file: "/workDir/workspace/ci-linchpin/linchpin/keys/linchpin_libvirt_key.pem"
              ansible_ssh_user: centos
  topology:
    topology_name: os-server-new
    resource_groups:
      - resource_group_name: os-server-new
        resource_group_type: openstack
        resource_definitions:
          - name: "ci-lp-cp-linchpin-libvirt"
            role: os_server
            flavor: {{ flavor | default('m1.small') }}
            image: "linchpin_libvirt_small"
            count: 1
            keypair: {{ keypair | default('linchpin-libvirt') }}
            networks:
              - {{ networks | default('provider_net_cci_4') }}
            security_groups: "wideopen"
        credentials:
          filename: clouds.yaml
          profile: ci-rhos
  layout:
    inventory_layout:
      vars:
        hostname: __IP__
      hosts:
        db-node:
          count: 1
          host_groups:
            - database
